From ac65c9cc494000e93571304bf71286ae12383968 Mon Sep 17 00:00:00 2001 From: Surya Poondla Date: Thu, 3 Sep 2026 11:29:41 -0700 Subject: [PATCH v3] Fix typos in logicalctl.c comments Also reword the comment preceding the final procsignal barrier in UpdateLogicalDecodingStatusEndOfRecovery(), whose last sentence had two grammar errors. Oversight in 67c20979ce72b8c236622e5603f9775968ff501c. Author: Chao Li Author: Shihao Zhong Author: Surya Poondla Discussion: https://postgr.es/m/F590A6A7-D8B1-4088-B07D-DA8EDB0F3925@gmail.com --- src/backend/replication/logical/logicalctl.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/src/backend/replication/logical/logicalctl.c b/src/backend/replication/logical/logicalctl.c index e5340880fa7..42a046618b1 100644 --- a/src/backend/replication/logical/logicalctl.c +++ b/src/backend/replication/logical/logicalctl.c @@ -28,7 +28,7 @@ * Asynchronous deactivation also avoids excessive toggling of the logical * decoding status in workloads that repeatedly create and drop a single * logical slot. On the other hand, this lazy approach can delay changes - * to effective_wal_level and the disabling logical decoding, especially + * to effective_wal_level and the disabling of logical decoding, especially * when the checkpointer is busy with other tasks. We chose this lazy approach * in all deactivation paths to keep the implementation simple, even though * laziness is strictly required only for end-of-recovery cases. Future work @@ -325,7 +325,7 @@ EnsureLogicalDecodingEnabled(void) } /* - * Ensure to abort the activation process in cases where there in an + * Ensure to abort the activation process in cases where there is an * interruption during the wait. */ PG_ENSURE_ERROR_CLEANUP(abort_logical_decoding_activation, (Datum) 0); @@ -354,9 +354,9 @@ EnableLogicalDecoding(void) } /* - * Set logical info WAL logging in shmem. All process starts after this - * point will include the information required by logical decoding to WAL - * records. + * Set logical info WAL logging in shmem. All processes starting after + * this point will include the information required by logical decoding in + * WAL records. */ LogicalDecodingCtl->xlog_logical_info = true; @@ -382,7 +382,7 @@ EnableLogicalDecoding(void) * to decode the transaction during the logical decoding initialization. * * There is a theoretical case where a transaction decides whether to - * include logical-info to WAL records before getting an XID. In this + * include logical-info in WAL records before getting an XID. In this * case, the transaction won't appear in xl_running_xacts. * * For operations that do not require an XID assignment, the process @@ -676,10 +676,10 @@ UpdateLogicalDecodingStatusEndOfRecovery(void) /* * Ensure all running processes have the updated status. We don't need to * wait for running transactions to finish as we don't accept any writes - * yet. On the other hand, we need to wait for synchronizing - * XLogLogicalInfo even if we've not updated the status above as the - * status have been turned on and off during recovery, having running - * processes have different status on their local caches. + * yet. On the other hand, we need to wait for XLogLogicalInfo to be + * synchronized even if we've not updated the status above, as the status + * may have been turned on and off during recovery, leaving running + * processes with different values in their local caches. */ if (IsUnderPostmaster) WaitForProcSignalBarrier( -- 2.39.5 (Apple Git-154)