Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Connection leak monitoring in GlassFish

Tags:

java

glassfish

Since as in some time the application throws a java.sql.SQLException: Error in allocating a connection. Cause: In-use connections equal max-pool-size and expired max-wait-time I have enable monitoring JDBC Connection Pool on the relevant server instance from glass fish admin web console.

Then i remote debug the application where i hold the debug point at after get connection but before close it. Then i refresh the web administration console and check the value for NumConnFree Resource Statistics which still shows the initial value of 8. Since I am currently using a connection, it should be 7 right?

Any one face this kind of situation. I am not sure its a problem with administration web console. Also what are other best way to monitor connection leaks? My goal was to check the value of NumPotentialConnLeak property and check the logs specific to any leaks. But since i faced above problem i am not sure the administration console shows correct data.

like image 259
Harshana Avatar asked Oct 29 '25 05:10

Harshana


1 Answers

Not sure if you are looking at this thread anymore but I found this very useful

http://pe-kay.blogspot.ca/2011/10/using-glassfish-monitoring-and-finding.html?m=1

like image 124
allegjdm93 Avatar answered Oct 31 '25 01:10

allegjdm93