Post

Since PgBouncer 1.24 that one is mostly handled by default: max_prepared_statements is 200, so protocol-level named statements follow the client across server connections. SQL-level PREPARE/EXECUTE are still forwarded as-is, and those are the ones that still bite.