Hello,

I noticed that with Oracle drivers you cannot "kill" a busy connection
by closing it (since close(), _getPC(), isOpen() and stmt.close() all
will synchronize on the (busy) physical connection.

I noticed this in a custom persistence layer, so I thought to check out
if DBCP handles this situation.

I have a test program here:

https://gist.github.com/ecki/345ee08ac97820972fe7

First of all it does not log DBCP messages. I am not sure what is
needed to get it going. As you can see in the output the deliberate
debug() message is printed so the general LogFactory should be set up.

When I run the program with acfg.setRemoveAbandonedTimeout(12) it
suceeds, since the c3 is only idle for 10s. When I run it with (4) it
will (so it seems) close the connection and I get a exception on next
use. However I dont see a log message about the abandoned connection
and the usage tracking. Ideas?

A second thing, from the abandoned tracker I had the impression the
usage is counted at the begin of exec. So if a execution takes 20s as
in my case, it should be considered abandoned. But it seems not to be
the case. Is it recognizing it is busy when the exec does not return?
If this is the case, is there also a way to kill/destroy connections
beeing used too long?

Gruss
Bernd

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@commons.apache.org
For additional commands, e-mail: user-h...@commons.apache.org

Reply via email to