← ALL PROJECTS
P-072024IC

CONNECTION-POOL AUTOPILOT

An adaptive pooler that models pool saturation as a queueing system and resizes itself from live telemetry — killing tail latency spikes during traffic surges.

-63%
p99 UNDER SURGE
-28%
POOL WASTE
0
INCIDENTS

An adaptive connection pooler that models saturation as a queueing system and resizes itself from live telemetry, killing the tail-latency spikes that traffic surges used to cause.

The problem

Statically-sized pools are wrong twice: too small and they queue under surge, too big and they waste connections and overwhelm the database. Hand-tuning them is a full-time job that's stale the moment traffic shifts.

Approach

  • Treat the pool as an M/M/c queue and track wait time, not just utilisation.
  • Resize on observed queue wait, with hysteresis to avoid thrashing.
  • Feed decisions from Prometheus metrics already being collected — zero new agents.

Results

p99 under surge dropped 63%, pool waste fell 28%, and surge-induced timeout incidents went to zero across the fleet.

/ STACK
GoPostgreSQLPgBouncerPrometheus