]> granicus.if.org Git - postgresql/commitdiff
Fix Hot Standby feedback sending when streaming busily.
authorHeikki Linnakangas <heikki.linnakangas@iki.fi>
Thu, 16 Jan 2014 21:05:02 +0000 (23:05 +0200)
committerHeikki Linnakangas <heikki.linnakangas@iki.fi>
Thu, 16 Jan 2014 21:15:41 +0000 (23:15 +0200)
Commit 6f60fdd7015b032bf49273c99f80913d57eac284 accidentally removed a
call to XLogWalRcvSendHSFeedback() after flushing received WAL to disk.
The consequence is that when walsender is busy streaming WAL, it doesn't
send HS feedback messages. One is sent if nothing is received from the
master for 100ms, but if there's a steady stream of WAL, it never happens.

Backpatch to 9.3.

Andres Freund and Amit Kapila

src/backend/replication/walreceiver.c

index 24f0b4ac6d2e57a6223b2a306cfbdf2cc67c21f8..1fbd33ef61b004d3940a5e17f80007f051e28084 100644 (file)
@@ -1007,7 +1007,10 @@ XLogWalRcvFlush(bool dying)
 
                /* Also let the master know that we made some progress */
                if (!dying)
+               {
                        XLogWalRcvSendReply(false, false);
+                       XLogWalRcvSendHSFeedback(false);
+               }
        }
 }