From: Robert Haas Date: Fri, 25 Mar 2011 15:23:39 +0000 (-0400) Subject: Make walreceiver send a reply after receiving data but before flushing it. X-Git-Tag: REL9_1_ALPHA5~19 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=30f6136f28a6bf9eedcbf41038d5b021169bc0b9;p=postgresql Make walreceiver send a reply after receiving data but before flushing it. It originally worked this way, but was changed by commit a8a8a3e0965201df88bdfdff08f50e5c06c552b7, since which time it's been impossible for walreceiver to ever send a reply with write_location and flush_location set to different values. --- diff --git a/src/backend/replication/walreceiver.c b/src/backend/replication/walreceiver.c index 47a980db20..f6259e4e30 100644 --- a/src/backend/replication/walreceiver.c +++ b/src/backend/replication/walreceiver.c @@ -317,6 +317,9 @@ WalReceiverMain(void) while (walrcv_receive(0, &type, &buf, &len)) XLogWalRcvProcessMsg(type, buf, len); + /* Let the master know that we received some data. */ + XLogWalRcvSendReply(); + /* * If we've written some records, flush them to disk and let the * startup process and primary server know about them.