Hi Laurenz,

On 7/9/19 5:16 AM, Laurenz Albe wrote:
On Thu, 2019-06-27 at 10:06 -0400, Jesper Pedersen wrote:
Here is a patch for the pg_receivewal documentation to highlight that
WAL isn't acknowledged to be applied.

I think it is a good idea to document this, but I have a few quibbles
with the patch as it is:

- I think there shouldn't be commas after the "note" and before the "if".
   Disclaimer: I am not a native speaker, so I am lacking authority.

- The assertion is wrong.  "on" (remote flush) is perfectly fine
   for synchronous_commit, only "remote_apply" is a problem.

- There is already something about "--synchronous" in the "Description"
   section.  It might make sense to add the additional information there.

How about the attached patch?


Thanks for the review, and the changes.

However, I think it belongs in the --synchronous section, so what about moving it there as attached ?

Best regards,
 Jesper
>From 6cd525b365f3afcdb63f478c4410d6e20ca2f6e0 Mon Sep 17 00:00:00 2001
From: jesperpedersen <jesper.peder...@redhat.com>
Date: Tue, 9 Jul 2019 13:14:25 -0400
Subject: [PATCH] Highlight that pg_receivewal doesn't acknowledge that WAL has
 been applied, and as such synchronous-commit needs to be remote_write or
 lower.

Authors: Laurenz Albe and Jesper Pedersen
Review-by: Laurenz Albe
---
 doc/src/sgml/ref/pg_receivewal.sgml | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/doc/src/sgml/ref/pg_receivewal.sgml b/doc/src/sgml/ref/pg_receivewal.sgml
index 0506120c00..46605db662 100644
--- a/doc/src/sgml/ref/pg_receivewal.sgml
+++ b/doc/src/sgml/ref/pg_receivewal.sgml
@@ -207,6 +207,13 @@ PostgreSQL documentation
         server as a synchronous standby, to ensure that timely feedback is
         sent to the server.
        </para>
+
+       <para>
+        Note that while WAL will be flushed with this setting,
+        it will never be applied, so <xref linkend="guc-synchronous-commit"/> must
+        not be set to <literal>remote_apply</literal> if <application>pg_receivewal</application>
+        is the only synchronous standby.
+       </para>
       </listitem>
      </varlistentry>
 
-- 
2.21.0

Reply via email to