When I switch to Reactor-Netty 0.9.5.RELEASE (Spring Boot 2.5.RELEASE), connection pool metrics aggregation change.
I use a named connection pool, as for example:
ConnectionProvider.create("a_name", 100);
When I look at metrics, it seems I get a Gauge per opened connection:
reactor_netty_connection_provider_a_name_total_connections{id="211417729",remote_address="remote.host:443",} 1.0
reactor_netty_connection_provider_a_name_total_connections{id="211417729",remote_address="remote.host:443",} 1.0
reactor_netty_connection_provider_a_name_total_connections{id="211417729",remote_address="remote.host:443",} 1.0
reactor_netty_connection_provider_a_name_total_connections{id="211417729",remote_address="remote.host:443",} 1.0
reactor_netty_connection_provider_a_name_total_connections{id="-928004310",remote_address="remote.host:443",} 1.0
reactor_netty_connection_provider_a_name_total_connections{id="1727380098",remote_address="remote.host:443",} 1.0
...
NB: I use Apache ab to perform so light tests with concurrency
That makes the metrics unusable cause I have no mean to know what the actual pool total size is. If I go back to prior versions, using something like:
ConnectionProvider.fixed("a_name", 100);
I always get one Gauge with - I assume - accurate total connections.
To bring the full picture, I'd like to have the ratio between configured max pool size and actual pool size (connections acquired in pool, no matter their state).
Am I misusing or misunderstanding something ?
Thanks in advance.