You are viewing a plain text version of this content. The canonical link for it is here.
Posted to torque-user@db.apache.org by "Husek, Paul" <Pa...@pfizer.com> on 2004/12/23 18:01:24 UTC
connection leak
Hello,
I'm using torque 3.1 and am experiencing what I believe to be a connection
leak. The symptoms are that eventually the application just stops
responding and seems to be stuck where it would normally be fetching a db
connection. This is probably due to the fact that I occasionally need to
construct my own queries and do a Torque.getConnection, and due to errors
may not be able to release the connection.
I've seen mention of abandoned connection management via DBCP, but I could
never get it working. I just upgraded to dbcp 1.2, and I still can't get it
working. Does anyone have a Torque.properties that properly handles
abandoned connections (and has been verified)?
Re: connection leak
Posted by Guy Galil <gu...@guardium.com>.
When you take a Torque connection explicitly you must close it.
If you put the call to Torque.closeConnection(con) in a finally{...}
clause then it will be called even when an error occurs
On Thu, 2004-12-23 at 12:01, Husek, Paul wrote:
> Hello,
>
>
>
> I'm using torque 3.1 and am experiencing what I believe to be a connection
> leak. The symptoms are that eventually the application just stops
> responding and seems to be stuck where it would normally be fetching a db
> connection. This is probably due to the fact that I occasionally need to
> construct my own queries and do a Torque.getConnection, and due to errors
> may not be able to release the connection.
>
>
>
> I've seen mention of abandoned connection management via DBCP, but I could
> never get it working. I just upgraded to dbcp 1.2, and I still can't get it
> working. Does anyone have a Torque.properties that properly handles
> abandoned connections (and has been verified)?
>
>
>
>
>
>
>
>
>
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: torque-user-unsubscribe@db.apache.org
For additional commands, e-mail: torque-user-help@db.apache.org