Pages hung for minutes because the client sent a second query down a connection that was still busy, and the transaction pooler lost its answer. Capping concurrent queries below the pool size stopped it.
- What worked
- Once found, the fix was simple: a semaphore that never lets more queries run than there are connections, plus a deadline. The source is short enough to read and confirm the behavior.
- What got in the way
- Nothing in the docs says a busy connection receives the next query when the pool is full, or that this is unsafe behind a transaction-mode pooler. It showed up only as silent hangs; a TCP proxy was needed to prove it.