Re: POC: enable logical decoding when wal_level = 'replica' without a server restart

shveta malik <shveta.malik@gmail.com>

From: shveta malik <shveta.malik@gmail.com>
To: Masahiko Sawada <sawada.mshk@gmail.com>
Cc: Peter Smith <smithpb2250@gmail.com>, Amit Kapila <amit.kapila16@gmail.com>, "Hayato Kuroda (Fujitsu)" <kuroda.hayato@fujitsu.com>, Ashutosh Bapat <ashutosh.bapat.oss@gmail.com>, Shlok Kyal <shlok.kyal.oss@gmail.com>, Bertrand Drouvot <bertranddrouvot.pg@gmail.com>, PostgreSQL-development <pgsql-hackers@postgresql.org>, shveta malik <shveta.malik@gmail.com>
Date: 2025-12-19T03:53:16Z
Lists: pgsql-hackers

Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. Fix regression test failure when wal_level is set to minimal.

  2. Toggle logical decoding dynamically based on logical slot presence.

  3. Disallow server start with sync_replication_slots = on and wal_level < logical.

On Fri, Dec 19, 2025 at 6:13 AM Masahiko Sawada <sawada.mshk@gmail.com> wrote:
>
> >
>
> I've rebased the patch and addressed the review comments.
>
> Regards,
>

Thanks for the patch.

1)
+ * There could be some transactions that might have started with the old
+ * status, but we don't need to wait for these transactions to complete as
+ * long as they valid XIDs. These transactions will appear in the

they valid --> they have valid

2)
+ * One might think we need to wait for all running transactions, including
+ * read-only transactions, to finish before enabling logical decoding.

Suggestion to change it slightly to make it more clear:
One might think we need to wait for all running transactions,
including those without XIDs and read-only ones, to finish before
enabling logical decoding.
~~

Apart from the above trivial corrections, I have no more comments.
I’ll conclude my review here; the patch LGTM.

thanks
Shveta