Re: pg_recvlogical cannot create slots with failover=true

From: Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>
To: Peter Eisentraut <peter(at)eisentraut(dot)org>
Cc: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, "Zhijie Hou (Fujitsu)" <houzj(dot)fnst(at)fujitsu(dot)com>, "Hayato Kuroda (Fujitsu)" <kuroda(dot)hayato(at)fujitsu(dot)com>, "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: pg_recvlogical cannot create slots with failover=true
Date: 2025-06-30 03:41:54
Message-ID: CAD21AoBRRRDS5dZEeuOb5x-EnHUWKwLXuLf_H_WGYnxvObLn5w@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Jun 30, 2025 at 2:37 AM Peter Eisentraut <peter(at)eisentraut(dot)org> wrote:
>
> On 22.06.25 15:38, Peter Eisentraut wrote:
> > On 17.06.25 20:19, Masahiko Sawada wrote:
> >>>> Ideally, we should change both to maintain consistency across various
> >>>> slot options. OTOH, as we have already described these options as: "
> >>>> The --two-phase and --failover options can be specified with
> >>>> --create-slot.", it is clear that these are slot options. The previous
> >>>> version docs have a description: "The --two-phase can be specified
> >>>> with --create-slot to enable decoding of prepared transactions." which
> >>>> makes it even more clear that the two-phase is a slot option. The
> >>>> options are named similarly in pg_create_logical_replication_slot API
> >>>> and during CREATE SUBSCRIPTION, so, to some level, there is a
> >>>> consistency in naming of these options across all APIs/tools. But,
> >>>> their usage in a tool like pg_recvlogical could be perceived
> >>>> differently as well, so it is also okay to consider naming them
> >>>> differently.
> >>>
> >>> Also note that we have a new pg_createsubscriber --enable-two-phase.
> >>
> >> Yeah, I also noticed the precedent.
> >>
> >>> It would be nice if there was more consistency between similar/related
> >>> tools.
> >>
> >> I've attached the patch. Feedback is very welcome.
> >
> > This looks fine to me, but I would keep the old name --two-phase as
> > well. You could mark it as deprecated. No need to make a hard break.
>
> I have committed your patch with this change.
>

Thank you for taking over the patch! I was unable to work on this last
week due to other work.

Regards,

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

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message vignesh C 2025-06-30 04:13:11 Re: pg_logical_slot_get_changes waits continously for a partial WAL record spanning across 2 pages
Previous Message Dilip Kumar 2025-06-30 03:25:45 Re: Replace magic numbers with strategy numbers for B-tree indexes