The Apache commons DBCP component provides Connection pooling for JDBC connections. This project is for learning how DBCP connection pooling works.
A simple Java class uses the DBCP API and we use Onyem JTracer to trace the calls.
Read How does DBCP work? for the analysis of DBCP.
To simply view the results, download this project and open results/jtrace in Onyem reader. Download the reader here for your plaform.
To run the program you need to provide the location of the Onyem agent. This needs to be specified in the pom.xml in the properties section as shown below.
<!-- Configure Onyem JTracer agent path -->
<properties>
<agent-path>/opt/onyem-jtracer-linux-x64/agent/libjtracer-agent.so</agent-path>
<properties>
For windows users, the path to the agent dll needs to be provided.
Run the project by invoking the maven command below.
mvn clean install exec:exec
The output of the execution is stored in results/out