News for hackers. Stuff that matters.
Re:PgBouncer is useful, important, and fraught with peril by dharmab on Friday September 08, 2023 @10:05AM (#37433657)
If you limit yourself to a subset of Postgres' features, connections can become your bottleneck. I work with a production system where the major scaling constraints are 1) the VM capacity of the cloud region it runs in and 2) available connections to Postgres
Re:PgBouncer is useful, important, and fraught with peril by Deadron on Friday September 08, 2023 @10:45AM (#37434168)
To be clear pgbouncer does not add connections to postgres or remove the connection bottleneck. Its still there under the covers. If you are saturating your connections it will not be able to improve on throughput. It sounds like you need a different architecture to allow for queueing work. The approach pgbouncer takes may actually reduce performance overall as it will intermix work on the pg instance which, if you are already saturating the database, will slow down other operations overall.
Re:PgBouncer is useful, important, and fraught with peril by dharmab on Friday September 08, 2023 @11:14AM (#37434603)
Yup, one of the things we're doing is moving parts of the system away from Postgres into queues.