commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mark Thomas <ma...@apache.org>
Subject Re: Deadlock in DBCP and Pooling
Date Sat, 19 Dec 2009 11:02:21 GMT
On 19/12/2009 00:02, Pawan Singh wrote:
> I am getting a deadlock in the following place very occasionally. My code is
> set up exactly as the examples suggest on the DBCP site.
> 
> The code seems to be deadlocked at:
> 
> GenericObjectPool.borrowObject() line:1104  <--- this code is in
> WHEN_EXHAUSTED_BLOCK and is waiting on latch.wait().
> PoolingDataSource.getConnection() line: 96
> 
> My set up does not initialize the max or min connections at all with the
> understanding that the pool will allocate new connections as needed. Is the
> deadlock caused by the fact that someone did not return the connection to
> the pool and there is a max limit on it? How do I find how many connections
> are in the pool and who is using them?
> 
> One last piece of information - I am using DBCP and Pool in a J2SE app.

Do you mean deadlocked or blocked. There is a difference. A thread dump
would help considerably here.

What versions are dbcp and pool are you using?

Mark



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


Mime
View raw message