Add WalRcvGetState() to retrieve the state of a WAL receiver
authorMichael Paquier <michael@paquier.xyz>
Tue, 4 Nov 2025 03:57:36 +0000 (12:57 +0900)
committerMichael Paquier <michael@paquier.xyz>
Tue, 4 Nov 2025 03:57:36 +0000 (12:57 +0900)
commite0ca61e7c4d55c34d67a3cc6fa0bdea2f41d2cf2
tree288580385b939c818993f17c0c9f4654f8bdaa0f
parent17b2d5ec759c0d26b29def7e57f51d0515ddca1f
Add WalRcvGetState() to retrieve the state of a WAL receiver

This has come up as useful as an alternative of WalRcvStreaming(), to be
able to do sanity checks based on the state of a WAL receiver.  This
will be used in a follow-up commit.

Author: Xuneng Zhou <xunengzhou@gmail.com>
Discussion: https://postgr.es/m/19093-c4fff49a608f82a0@postgresql.org
src/backend/replication/walreceiverfuncs.c
src/include/replication/walreceiver.h