Re: When extended query protocol ends?

Поиск
Список
Период
Сортировка
От Jelte Fennema-Nio
Тема Re: When extended query protocol ends?
Дата
Msg-id CAGECzQSKPkKVEcjZYd_TXcbH2ZeDL1hDFUWmPkneFmqAXfAQZQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: When extended query protocol ends?  (Vladimir Sitnikov <sitnikov.vladimir@gmail.com>)
Ответы Re: When extended query protocol ends?  (Vladimir Sitnikov <sitnikov.vladimir@gmail.com>)
Список pgsql-hackers
On Wed, 21 Feb 2024 at 17:07, Vladimir Sitnikov
<sitnikov.vladimir@gmail.com> wrote:
> From many measurements we know that insert into table(id, name) values(?,?),(?,?),(?,?) is much more efficient than
> sending individual bind-exec-bind-exec-bind-exec-sync messages like "insert into table(id, name) values(?,?)"
> For instance, here are some measurements: https://www.baeldung.com/spring-jdbc-batch-inserts#performance-comparisons
> Based on that measurements I assume there's a non-trivial per-message overhead.

That's quite a different case. When splitting a multi insert statement
you're going to duplicate some work, e.g. executor initialization and
possibly even planning. But when replacing one Query packet with
Parse-Bind-Exec-Sync, these 4 packets are not duplicating such
expensive work. The only thing they should be doing extra is a bit of
packet parsing, which is very cheap.



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

Предыдущее
От: Ashutosh Bapat
Дата:
Сообщение: Re: Test to dump and restore objects left behind by regression
Следующее
От: Peter Eisentraut
Дата:
Сообщение: Re: Test to dump and restore objects left behind by regression