Bug 63705

Summary: The tomcat pool doesn't register all connection through JMX
Product: Tomcat Modules Reporter: Borja <borjafg95>
Component: jdbc-poolAssignee: Tomcat Developers Mailing List <dev>
Status: NEW ---    
Severity: normal    
Priority: P2    
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS:    
Attachments: Screenshot of the pool in JConsole

Description Borja 2019-08-29 08:11:31 UTC
Created attachment 36742 [details]
Screenshot of the pool in JConsole

I used the "JConsole" tool to monitor a tomcat connection pool through JMX.

The pool indicated that there were four idle connections, but only two of them were visible in the monitoring tool.

In addition, the initial size of the pool was six and six connections were created (I checked it by debugging the code), but for some reason two of them were closed, and the pool was left with the minimum number of idle connections (four connections).

I guess it's the normal behavior of the pool. However, if there are four connections, all of them should be registered through JMX, not just two.


Tomcat pool:
  - Initial size: 6
  - Min idle: 4
  - Max idle: 30
  - Max active: 40


Tomcat version: 9.0.22