title: Java EE show how many connections left in the connection pool
body: <p>My system encounter some connection leak in connection pool. I would like to list down some statistic of the connection pool regularly, how can I do that? For example, Current Capacity, Active Connections High Count, Connections Total Count, Leaked Connection Count and etc.</p>
  
  <p>I am using <code>javax.sql.DataSource</code> to retrieve the connection from connection pool. But I couldn't find any interface that can retrieve those connection pool information. Any ideas?</p>
  
  <p>I am using Oracle DB and <code>Java EE</code> as my server side script.</p>