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

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

> Hacker News story 49711486 · language: en · submitted 2026-09-15
> Web version: https://zeli.app/story/49711486
> About this feed: https://zeli.app/llms.txt · Agent guide: https://zeli.app/skill.md

▲ 8 · by [asenna](<https://news.ycombinator.com/user?id=asenna>) · 💬 10
[original](<https://blog.simbastack.com/four-round-trips-six-months/>) · [HN discussion](<https://news.ycombinator.com/item?id=49711486>)

## Summary

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.

## Key quote

> Right arithmetic, wrong sentence. Nobody measured the latency.

## HN discussion (10 comments)

### [ProjectBarks](<https://news.ycombinator.com/item?id=49730348>)

> \> "The uncomfortable part is that the fix already existed. Claude Code, Anthropic's command-line coding agent".
>
> It sounds like there could be something extremely interesting in this article, but the writing style is really off-putting.
>
> \> "on staging first and then on production at 23:40"
>
> Why does the reader need to know the exact minute-to-minute timeline?

### [tecleandor](<https://news.ycombinator.com/item?id=49731004>)

> To the author:
>
> First of all, you still have the images problem (among others). Loading your home site takes around 60MB of downloads, including the autoloading 40MB MP4 file. Reduce resolution and compress. You don't need a phone to reproduce that, you just need to open your web browser development tools and reload the site to see how heavy is it. Also, the memory use calculation is off, but that's not important because probably an LLM did it.
>
> Second, your API in karibukit.com is down
>
> Don't rely that much in the LLM. Check things with your own eyes.

### [OG_BME](<https://news.ycombinator.com/item?id=49730338>)

> Completely AI written unfortunately

---

## Cite

- Page: https://zeli.app/story/49711486
- Date: 2026-09-15
- Source: blog.simbastack.com (https://blog.simbastack.com/four-round-trips-six-months/)
- Hacker News: https://news.ycombinator.com/item?id=49711486

## Other languages

- zh: https://zeli.app/zh/story/49711486 · markdown: https://zeli.app/zh/story/49711486.md
- ja: https://zeli.app/ja/story/49711486 · markdown: https://zeli.app/ja/story/49711486.md
- ko: https://zeli.app/ko/story/49711486 · markdown: https://zeli.app/ko/story/49711486.md
- de: https://zeli.app/de/story/49711486 · markdown: https://zeli.app/de/story/49711486.md
- es: https://zeli.app/es/story/49711486 · markdown: https://zeli.app/es/story/49711486.md
- ru: https://zeli.app/ru/story/49711486 · markdown: https://zeli.app/ru/story/49711486.md
