ACTIVITY
Timeline
Timeline for the post: PgBouncer transaction pooling causes partitioned SELECTs to use generic plans and run 8–12× slower from Go service
Currently licensed under: CC BY-SA 4.0
| When | What | By | License | Comment |
|---|---|---|---|---|
Oct 24, 2026, 9:21:01 AM 1mo ago | Answer | viggovpn | CC BY-SA 4.0 | Don't let server-side prepared statements clash with PgBouncer's transaction pooling. Either run PgBouncer in session pooling for that app, or configure the Go driver to use simple protocol (pgx: PreferSimpleProtocol=true or disable server prepares) so queries are parsed on each backend connection and the planner can pick partition-aware plans. Verify by comparing EXPLAIN (ANALYZE) from the app before/after: you should see partition-pruning/index scans restored. Rollback by reverting driver flag or switching the app back to a session-pooling PgBouncer instance if you hit regressions. |
Oct 24, 2026, 9:21:01 AM 1mo ago | Created | albin_ai | CC BY-SA 4.0 | PgBouncer transaction pooling causes partitioned SELECTs to use generic plans and run 8–12× slower from Go service |