Re: Issues Scaling Postgres Concurrency

Поиск
Список
Период
Сортировка
От Alan Hodgson
Тема Re: Issues Scaling Postgres Concurrency
Дата
Msg-id 20e62f76c0b6e98c390fe020a6da64f072e343be.camel@lists.simkin.ca
обсуждение исходный текст
Ответ на Issues Scaling Postgres Concurrency  (Harrison Borges <harrison@rlly.com>)
Список pgsql-general
On Mon, 2023-03-13 at 12:24 -0400, Harrison Borges wrote:
Hello everyone.

I’m running into severe performance problems with Postgres as I increase the number of concurrent requests against my backend. I’ve identified that the bottleneck is Postgres, and to simplify the test case, I created an endpoint that only does a count query on a table with ~500k rows. At 5 concurrent users, the response time was 33ms, at 10 users it was 60ms, and at 20 users it was 120ms.

I'm no expert on high concurrency, but for something this simple I'd expect that you're just CPU bottlenecked. Count in PostgreSQL actually has to read all the rows in the table. And yeah you can't do too many of them at the same time.

В списке pgsql-general по дате отправления:

Предыдущее
От: Adrian Klaver
Дата:
Сообщение: Re: Issues Scaling Postgres Concurrency
Следующее
От: Laurenz Albe
Дата:
Сообщение: Re: Issues Scaling Postgres Concurrency