Subject Re: Should (Could) FBStatements be held in WeakHashMap
Author Roman Rokytskyy
Mark,

> Well yes, I agree sort off, it's nice to explicitly know about open
> statements, but when it's this reference that is the only link that
> holds them open, wouldn't it be nice to then close them.

I'm still thinking about your suggestion. I'm sure one cannot solve it
with AspectJ, but your idea about WeakHashMap might work. Can you try
replacing that HashMap with WeakHashMap and adding finalize() method
to FBStatement:

protected void finalize() throws SQLException {
if (!closed)
close();
}

If you do not get resource leaks on server, then I think we can commit
your change. Sorry for arguing so long... Also I'm not convinced that
this is 100% correct, but we can try.

Thanks!
Roman