Asking c3p0 how many connections are in use
问题 Is there a way to programatically ask c3p0 how many of it's connections are being used, or perhaps logs when the pool is exhausted. 回答1: As indicated in the URL referenced by Austin's comment above, you can use JMX to inspect and modify running c3p0 PooledDataSources. You can also do so programmatically. c3p0's PooledDataSources have an elaborate API for inspecting their state: http://www.mchange.com/projects/c3p0/apidocs/com/mchange/v2/c3p0/PooledDataSource.html If you are using