Re: postgres_fdw: commit remote (sub)transactions in parallel during pre-commit

From: Etsuro Fujita <etsuro(dot)fujita(at)gmail(dot)com>
To: Fujii Masao <masao(dot)fujii(at)oss(dot)nttdata(dot)com>
Cc: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: postgres_fdw: commit remote (sub)transactions in parallel during pre-commit
Date: 2022-02-23 06:30:37
Message-ID: CAPmGK16sRsm30a_1dpWPkVoTANg=F3H1vLRLyek-Xcw_r7JPkQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Feb 22, 2022 at 1:03 AM Fujii Masao <masao(dot)fujii(at)oss(dot)nttdata(dot)com> wrote:
> On 2022/02/21 14:45, Etsuro Fujita wrote:
> > On Fri, Feb 18, 2022 at 1:46 AM Fujii Masao <masao(dot)fujii(at)oss(dot)nttdata(dot)com> wrote:
> >> I reviewed 0001 patch. It looks good to me except the following minor things. If these are addressed, I think that the 001 patch can be marked as ready for committer.

> >> + * Also determine to commit (sub)transactions opened on the remote server
> >> + * in parallel at (sub)transaction end.
> >>
> >> Like the comment "Determine whether to keep the connection ...", "determine to commit" should be "determine whether to commit"?
> >
> > Agreed. I’ll change it as such.

Done.

> Thanks! If that's updated, IMO it's ok to commit the 0001 patch.

Cool! Attached is an updated patch. Other changes other than that:
1) I added the curlevel parameter to
pgfdw_finish_pre_subcommit_cleanup() to avoid doing
GetCurrentTransactionNestLevel() there, as proposed, and 2) tweaked
comments a bit further, mostly for/in
pgfdw_finish_pre_commit_cleanup() and
pgfdw_finish_pre_subcommit_cleanup(). Barring objections, I’ll commit
the patch.

Thanks for reviewing!

Best regards,
Etsuro Fujita

Attachment Content-Type Size
v5-0001-postgres-fdw-Add-support-for-parallel-commit.patch application/octet-stream 19.1 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Daria Lepikhova 2022-02-23 07:09:02 Re: Assert in pageinspect with NULL pages
Previous Message Amit Kapila 2022-02-23 06:30:26 Re: Failed transaction statistics to measure the logical replication progress