Hi Hackers,
The current code comment says that the replication stream on a slot with the given targetLSN can't continue after a restart but even without a restart the stream cannot continue. The slot is invalidated and the walsender process is terminated by the checkpoint process. Attaching a small patch to fix the comment.
2022-10-19 06:26:22.387 UTC [144482] STATEMENT: START_REPLICATION SLOT "s2" LOGICAL 0/0
2022-10-19 06:27:41.998 UTC [2553755] LOG: checkpoint starting: time
2022-10-19 06:28:04.974 UTC [2553755] LOG: terminating process 144482 to release replication slot "s2"
2022-10-19 06:28:04.974 UTC [144482] FATAL: terminating connection due to administrator command
2022-10-19 06:28:04.974 UTC [144482] CONTEXT: slot "s2", output plugin "test_decoding", in the change callback, associated LSN 0/1E23AB68
2022-10-19 06:28:04.974 UTC [144482] STATEMENT: START_REPLICATION SLOT "s2" LOGICAL 0/0
Thanks,
Sirisha