Hello all,

I am very new to DBCP, and I wanted to easily see what happens in a
graphical way, so I created this tool:

  https://github.com/nicolas-raoul/Commons-DBCP-monitoring

Basically it is a modified DBCP that increments/decrements 2 variables:
- Number of threads using a connection
- Number of threads waiting for a connection

I just output +1/-1 lines to the output at the strategic places below:
- Beginning of AbandonedObjectPool.borrowObject (waiting++)
- End of AbandonedObjectPool.borrowObject (used++, waiting--)
- Beginning of AbandonedObjectPool.returnObject (used--)
- Beginning of AbandonedObjectPool.invalidateObject (used--)

Did I forgot some places where connections are borrowed/returned?
Are there better places?

Thank you very much for any feedback!
Nicolas Raoul
http://nicolas-raoul.blogspot.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to