views:

145

answers:

1

In my project Spring manages connection pool with org.apache.commons.dbcp.BasicDataSource class. Is possible to get how many connections are free or used in current time?

Thanks.

+2  A: 

From the javadocs, you should be able to read this from the getNumIdle() and getNumActive() methods, if you can get an instance of the BasicDataSource.

Phill Sacre
Thanks! wowowow
Sinuhe