On Wed, 25 Sept 2024 at 14:06, Amit Kapila <amit.kapil...@gmail.com> wrote:
>
> On Tue, Sep 24, 2024 at 9:42 PM vignesh C <vignes...@gmail.com> wrote:
> >
> > Reordered the docs to enable the subscription before creating the
> > table. For bi-directional replication, a publication refresh is
> > necessary on both nodes: a) First, refresh the publication on the old
> > version server to set the newly added tables to a ready state in the
> > pg_subscription_rel catalog.
> >
>
> This is not required for table-specific publications and isn't needed
> for the examples mentioned in the patch. So, I have removed this part
> and pushed the patch. BTW, you choose to upgrade the publisher first
> but one can upgrade the subscriber first as well. If so, we can add a
> note to the documentation.

Yes, users can upgrade either the publisher first and then the
subscriber, or the subscriber first and then the publisher. I felt
this note is necessary only for the "Steps to upgrade a two-node
logical replication cluster," as it may confuse users in other types
of logical replication with questions such as: a) Which subscriber
should be upgraded first? b) Which subscriptions should be disabled?
c) When should each subscription be enabled?
The attached patch includes a note for the same.

Regards,
Vignesh
From ce2fdb52368b57d9259eae5d383c1c351831a248 Mon Sep 17 00:00:00 2001
From: Vignesh C <vignes...@gmail.com>
Date: Wed, 25 Sep 2024 17:35:34 +0530
Subject: [PATCH v1] Add a note in upgrade of logical replication clusters
 page.

Add a note mentioning users can alternatively upgrade subscriber first
followed by the publisher.
---
 doc/src/sgml/logical-replication.sgml | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/doc/src/sgml/logical-replication.sgml b/doc/src/sgml/logical-replication.sgml
index 536d03995e..98a7ad0c27 100644
--- a/doc/src/sgml/logical-replication.sgml
+++ b/doc/src/sgml/logical-replication.sgml
@@ -2564,6 +2564,14 @@ ALTER SUBSCRIPTION
        </para>
       </step>
      </procedure>
+
+     <note>
+      <para>
+       In the steps described above, the publisher is upgraded first, followed
+       by the subscriber. Alternatively, the user can use similar steps to
+       upgrade the subscriber first, followed by the publisher.
+      </para>
+     </note>
     </sect3>
 
     <sect3 id="steps-cascaded-logical-replication-cluster">
-- 
2.34.1

Reply via email to