Re: Transactions involving multiple postgres foreign servers, take 2
От | Ranier Vilela |
---|---|
Тема | Re: Transactions involving multiple postgres foreign servers, take 2 |
Дата | |
Msg-id | CAEudQArYLAdtGt4va5LJtuLY2DLRxdppQjjSMyRwv_avBJwYCQ@mail.gmail.com обсуждение исходный текст |
Ответ на | RE: Transactions involving multiple postgres foreign servers, take 2 ("r.takahashi_2@fujitsu.com" <r.takahashi_2@fujitsu.com>) |
Ответы |
RE: Transactions involving multiple postgres foreign servers, take 2
|
Список | pgsql-hackers |
Em ter., 13 de jul. de 2021 às 01:14, r.takahashi_2@fujitsu.com <r.takahashi_2@fujitsu.com> escreveu:
Hi Sawada-san,Wouldn't it be better to explicitly initialize the pointer with NULL?
Thank you for your reply.
> Not sure but it might be possible to keep holding an xlogreader for
> reading PREPARE WAL records even after the transaction commit. But I
> wonder how much open() for wal segment file accounts for the total
> execution time of 2PC. 2PC requires 2 network round trips for each
> participant. For example, if it took 500ms in total, we would not get
> benefits much from the point of view of 2PC performance even if we
> improved it from 14ms to 1ms.
I made the patch based on your advice and re-run the test on the new machine.
(The attached patch is just for test purpose.)
I think it's common in Postgres.
static XLogReaderState *xlogreader = NULL;
* foreign_twophase_commit = disabled
2686tps
* foreign_twophase_commit = required (It is necessary to set -R ${RATE} as Ikeda-san said)
311tps
* foreign_twophase_commit = required with attached patch (It is not necessary to set -R ${RATE})
2057tps
Nice results.
regards,
Ranier Vilela
В списке pgsql-hackers по дате отправления: