While the validation query solution would be a good one, it unfortunately doesn't work for our application. Our pool may establish a connection to any one of over 200 different databases around the world, many of which we do not have any control over. Creating a maintainable validation query that will always return valid results is not really possible, considering that these databases may be Oracle, Sybase, DB2, Informix, MySQL, or others.

Kris

Mario Ivankovits wrote:

What do people think about possibly moving the code that
reclaims abandoned connections to a separate thread, similar to idle
object eviction?


The current solution is more defensive, only if an connection is needet and
the pool is nearly empty the abandoned process starts.
I think this is a good argument for not doing this within an thread which
aggresivley tries to kill such connections.



If you have issues like firewall or database timeouts closing
the connections, they can also be invalid when returned to the pool and
will remain available to the application until the idle object eviction
thread subsequently runs.


I dont know dbcp in detail for now, but as i have read, you could define a
"validation query" which runs on "release connection", "request connection"
and "async". So on database timeouts and firewall issues it might be better
to run this validation query on "request" !?!

Mario


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]





-- ===================================================== Kris Nuttycombe Associate Scientist Geospatial Data Services Group CIRES, National Geophysical Data Center/NOAA (303) 497-6337 [EMAIL PROTECTED] =====================================================







---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to