Re: Introduce XID age based replication slot invalidation
Srinath Reddy Sadipiralla <srinath2133@gmail.com>
From: Srinath Reddy Sadipiralla <srinath2133@gmail.com>
To: Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com>
Cc: Masahiko Sawada <sawada.mshk@gmail.com>, SATYANARAYANA NARLAPURAM <satyanarlapuram@gmail.com>, "Hayato Kuroda (Fujitsu)" <kuroda.hayato@fujitsu.com>,
John H <johnhyvr@gmail.com>, PostgreSQL-development <pgsql-hackers@postgresql.org>
Date: 2026-03-29T20:16:36Z
Lists: pgsql-hackers
Hello,
Thanks for the v5 patch set, I have reviewed and did initial testing on
v5 patch set, and it LGTM, except these
diff --git a/src/backend/replication/slot.c b/src/backend/replication/slot.c
index 286f0f46341..c2ff7e464f0 100644
--- a/src/backend/replication/slot.c
+++ b/src/backend/replication/slot.c
@@ -1849,7 +1849,7 @@
ReportSlotInvalidation(ReplicationSlotInvalidationCause cause,
else
{
/* translator: %s is a GUC variable
name */
- appendStringInfo(&err_detail,
_("The slot's xmin %u is %d transactions old, which exceeds the configured
\"%s\" value of %d."),
+ appendStringInfo(&err_detail,
_("The slot's catalog_xmin %u is %d transactions old, which exceeds the
configured \"%s\" value of %d."),
catalog_xmin, (int32) (recentXid - catalog_xmin), "max_slot_xid_age",
max_slot_xid_age);
}
while testing the active slot XID age invalidation (SIGTERM path) , i
observed that slot got invalidated , walsender was killed because of
SIGTERM , then starts the infinite-retry-cycle problem where
walreceiver starts walsender and walsender will try to use an invalidated
slot and dies, will think more on this.
--
Thanks,
Srinath Reddy Sadipiralla
EDB: https://www.enterprisedb.com/
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Fix the handling of two GUCs during upgrade.
- 72e6c08fea7c 19 (unreleased) cited