pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Amit Kapila <akapila@postgresql.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Fix inconsistent elevel in pg_sync_replication_slots() retry log
Date: Fri, 06 Mar 2026 05:35:08 +0000
Message-ID: <E1vyNq8-002cw5-2w@gemulon.postgresql.org> (raw)

Fix inconsistent elevel in pg_sync_replication_slots() retry logic.

The commit 0d2d4a0ec3 allowed pg_sync_replication_slots() to retry sync
attempts, but missed a case, when WAL prior to a slot's
confirmed_flush_lsn is not yet flushed locally.

By changing the elevel from ERROR to LOG, we allow the sync loop to
continue. This provides the opportunity for the slot to be synchronized
once the standby catches up with the necessary WAL.

Author: Zhijie Hou <houzj.fnst@fujitsu.com>
Reviewed-by: shveta malik <shveta.malik@gmail.com>
Reviewed-by: Amit Kapila <amit.kapila16@gmail.com>
Discussion: https://postgr.es/m/CAFPTHDZAA+gWDntpa5ucqKKba41=tXmoXqN3q4rpjO9cdxgQrw@mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/f1ddaa15357fccb03dea371f8cb481ce2c5e4808

Modified Files
--------------
doc/src/sgml/func/func-admin.sgml          | 4 +++-
src/backend/replication/logical/slotsync.c | 6 +++++-
2 files changed, 8 insertions(+), 2 deletions(-)



Message-ID: <E1vyNq8-002cw5-2w@gemulon.postgresql.org>
Permalink:  ../E1vyNq8-002cw5-2w@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1vyNq8-002cw5-2w@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-committers@postgresql.org
  Cc: akapila@postgresql.org, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: Fix inconsistent elevel in pg_sync_replication_slots() retry log
  In-Reply-To: <E1vyNq8-002cw5-2w@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox