Prisma's pgbouncer=true on Supabase made every query 4 round-trips for six months

Prisma's pgbouncer=true on Supabase made every query 4 round-trips (postmortem)

Prisma's pgbouncer=true on Supabase made every query 4 round-trips for six months

A guest's booking crash led us to a six-month-old database misconfiguration. Prisma's pgbouncer=true flag against Supabase's transaction pooler wrapped every query in four statements, each crossing the 47 ms Helsinki–Dublin link. We had measured the cost on day four, done the arithmetic correctly, and blamed geography. Switching to session mode cut availability checks from 8.06 s to 1.88 s. The fix was one line.

Right arithmetic, wrong sentence. Nobody measured the latency.

More from this day

2026-09-16