Re: Fix race between copying and dropping a replication slot

From: Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>
To: Zhijie Hou <houzhijie22(at)gmail(dot)com>
Cc: "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Fix race between copying and dropping a replication slot
Date: 2026-12-02 18:35:49
Message-ID: CAD21AoAUD8TqCsFpjuup2f8A80gFOBQK+ntoHF0rAEF54cig=Q@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Dec 1, 2026 at 7:08 PM Zhijie Hou <houzhijie22(at)gmail(dot)com> wrote:
>
> Hi,
>
> On Wed, Dec 2, 2026 at 10:20 AM Zhijie Hou wrote:
> >
> > On Wed, Dec 2, 2026 at 04:00 AM Masahiko Sawada wrote:
> > > On Tue, Dec 1, 2026 at 4:47 AM Zhijie Hou <houzhijie22(at)gmail(dot)com> wrote:
> > > >
> > > >
> > > > Thanks for the comments! Both comments have been addressed in v2 patch.
> > >
> > > Thank you for updating the patch! The patch looks good to me. Could
> > > you prepare the patch for back branches? The new isolation test uses
> > > the injection point 'replication-slot-create-begin', which exists
> > > only in v19 and later. For v17 and v18, I think we can have the same
> > > test
> > > if we add the injection point there too. What do you think?
> >
> > Yes, I agree. Added in the V3.
>
> One thing I forgot to mention is that adding the injection point test to
> PG17 and PG18 also requires setting wal_level = logical for the
> injection_points isolation test suite. If that seems undesirable on back
> branches, we can skip adding the isolation test there, as in the
> attached PG17-PG18 patch. The other patches can be found [1]

Thank you for preparing the patches. And I agree that adding wal_level
= logical is not suitable for back branches that don't have it now.
I've pushed the fix.

Regards,

--
Masahiko Sawada
Amazon Web Services: https://aws.amazon.com

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Alexander Nestorov 2026-12-02 18:39:27 Re: [PATCH] btree_gist: add cross-type integer operator support for GiST
Previous Message Dongpo Liu 2026-12-02 18:33:36 Re: pg_plan_advice: add NO_ scan and join method tags