Re: [PATCH] add concurrent_abort callback for output plugin

From: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>
To: Markus Wanner <markus(dot)wanner(at)enterprisedb(dot)com>
Cc: Ajin Cherian <itsajin(at)gmail(dot)com>, Markus Wanner <markus(at)bluegap(dot)ch>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: [PATCH] add concurrent_abort callback for output plugin
Date: 2021-03-31 13:18:49
Message-ID: CAA4eK1+V2rEDE6L2-yCbG9P37JBXUCgrzfKFb9GQgWrJANP-0A@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Mar 31, 2021 at 11:55 AM Markus Wanner
<markus(dot)wanner(at)enterprisedb(dot)com> wrote:
>
> On 31.03.21 06:39, Amit Kapila wrote:
> > I have slightly adjusted the comments, docs, and commit message. What
> > do you think about the attached?
>
> Thank you both, Amit and Ajin. This looks good to me.
>
> Only one minor gripe:
>
> > + a prepared transaction with incomplete changes, in which case the
> > + <literal>concurrent_abort</literal> field of the passed
> > + <literal>ReorderBufferTXN</literal> struct is set. This is done so that
> > + eventually when the <command>ROLLBACK PREPARED</command> is decoded, there
> > + is a corresponding prepared transaction with a matching gid.
>
> The last sentences there now seems to relate to just the setting of
> "concurrent_abort", rather than the whole reason to invoke the
> prepare_cb. And the reference to the "gid" is a bit lost. Maybe:
>
> "Thus even in case of a concurrent abort, enough information is
> provided to the output plugin for it to properly deal with the
> <command>ROLLBACK PREPARED</command> once that is decoded."
>

Okay, Changed the patch accordingly.

--
With Regards,
Amit Kapila.

Attachment Content-Type Size
v5-0001-Ensure-to-send-a-prepare-after-we-detect-concurre.patch application/octet-stream 3.3 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Sait Talha Nisanci 2021-03-31 13:26:34 Re: Crash in record_type_typmod_compare
Previous Message Masahiko Sawada 2021-03-31 13:17:09 Re: Flaky vacuum truncate test in reloptions.sql