Postgres - I can't replicate a slow query

In one of my personal projects I’ve implemented a GenServer to store slow queries. One of these queries was returning 17+s seconds to return a result, so I decided to investigate the reason. For the context, I’m using a Postgres database and use PgAdmin as UI to test some queries. The first step was to run the query on PgAdmin, but got a response immediately. Shouldn’t this query take 17+ seconds? ...

September 8, 2025 · 4 min