tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From alexis <>
Subject recovering connections on jdbc connection pool
Date Sun, 08 May 2011 14:42:01 GMT
Hello all, is there any way to recover lost connectios on a pool?

Here's the issue, for an application, using postgresql jdbc (same happens with mysql as i
tried), having query errors syntax or duplicated keys, actually no big deal, it throws an
sqlexception upon que sql error, as this call executes ~150 queries to insert, on each query
i lost the connection, so suddenly i have all my connections lost and my app useless.

How can i do from the catch clause of the SQLException to ask the pool to reconnect? Because
today we are in debug stage but soon to be production and when this happens (we've corrected
a lot of queries and situations but for sure some new one will arise) we need to restart the

thanks in advance. 
To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message