Re: Unused parameter in ProcessSlotSyncInterrupts() - Mailing list pgsql-hackers

From Nathan Bossart
Subject Re: Unused parameter in ProcessSlotSyncInterrupts()
Date
Msg-id aLHBbYv52F7ipoer@nathan
Whole thread Raw
In response to Unused parameter in ProcessSlotSyncInterrupts()  ("cca5507" <cca5507@qq.com>)
Responses Re: Unused parameter in ProcessSlotSyncInterrupts()
List pgsql-hackers
On Fri, Aug 29, 2025 at 10:40:25PM +0800, cca5507 wrote:
> When reading the code about slot sync, I find the $subject, attach a
> patch to fix it.

LGTM.  I looked through the original thread [0] for clues about the origins
of this parameter, but it's a very long thread, and ctrl+f didn't help.  It
seems to have become unused somewhere between v82 and v88 of the patch set,
though.  In v82, ProcessSlotSyncInterrupts() has the following code:

+    if (ShutdownRequestPending)
+    {
+        if (wrconn)
+            walrcv_disconnect(wrconn);
+        ereport(LOG,
+                errmsg("replication slot sync worker is shutting down on receiving SIGINT"));
+        proc_exit(0);
+    }

[0] https://postgr.es/m/514f6f2f-6833-4539-39f1-96cd1e011f23%40enterprisedb.com

-- 
nathan



pgsql-hackers by date:

Previous
From: Bertrand Drouvot
Date:
Subject: Generate pgstat_count_slru*() functions for slru using macros
Next
From: Jeff Davis
Date:
Subject: aio/README.md comments