Bolt connection pool size under high concurrency
0 reputation · 19 Mar 2023, 08:11 UTC
The precise goal is to identify the connection pool size threshold at which Neo4j Bolt session queueing latency emerges when client request concurrency exceeds the default capacity. Default pool sizing of 100 connections may not scale uniformly across workloads that interleave short read operations with longer write transactions. Understanding how pool saturation maps to observed request latency is essential for capacity planning in multi-tenant or high-throughput environments.
A key uncertainty involves the interaction between pool size, transaction timeout defaults, and isolation level settings under sustained concurrency. While the default timeout of -1 permits unconstrained transaction duration, and read-committed isolation can cause repeated reads, the combined effect on session queueing metrics is not explicitly quantified across Neo4j versions or deployment topologies. Page cache pressure and causal clustering replication lag may further complicate the latency profile.
What connection pool size triggers measurable queueing latency in a mixed read-write workload under sustained concurrent demand? How does adjusting the transaction timeout influence the point at which sessions are rejected or delayed? Are there supplementary Bolt metrics, beyond queue depth, that reliably indicate pool saturation before latency spikes become apparent?