MongoPoolGauge
What a MongoClient's connection pool says of itself, for a MongoDB store's pool (me.ahoo.wow.spi.store.StorePool): the most connections a server's pool opens (maxConnections) and how many check-outs wait now (waiting). The node bounds the store's queries by the first and reads the store's write pressure from the second. One gauge listens to every server pool the client opens: waiting sums their check-outs, maxConnections is one pool's size, the same for each.
It is a ConnectionPoolListener the client is built with: the host adds it to the MongoClient it or Spring Boot makes. An application that builds its own client adds it itself, with applyTo after the settings that size the pool (a connection string's maxPoolSize, say), and gives it to the store as a bean (the store's pool-gauge option names it when there are several):
val gauge = MongoPoolGauge()
val settings = MongoClientSettings.builder()
.applyConnectionString(uri)
.applyToConnectionPoolSettings(gauge::applyTo)
.build()
val client = MongoClients.create(settings)A store without one, or with one no client was built with, says nothing of its pool: its queries take the default bound.