Re: [PATCH] Preserve replication origin OIDs in pg_upgrade - Mailing list pgsql-hackers

From Zsolt Parragi
Subject Re: [PATCH] Preserve replication origin OIDs in pg_upgrade
Date
Msg-id CAN4CZFPdFHwnew+wxt4UcXyjMYc3aXeR0XsR6_wZ=LEMGWEJFQ@mail.gmail.com
Whole thread
In response to Re: [PATCH] Preserve replication origin OIDs in pg_upgrade  (Ajin Cherian <itsajin@gmail.com>)
Responses Re: [PATCH] Preserve replication origin OIDs in pg_upgrade
List pgsql-hackers
Hello

+# Verify that the subscription related replication origins are
preserved after upgrade.
+my $post_roident_rows = $new_sub->safe_psql('postgres',
+    "SELECT s.subname, o.roident
+     FROM pg_subscription s
+     JOIN pg_replication_origin o ON o.roname = 'pg_' || s.oid::text
+     ORDER BY s.subname"
+);
+for my $row (split /\n/, $post_roident_rows)
+{
+    my ($subname, $roident) = split /\|/, $row;
+    is($roident, $pre_upgrade_roident{$subname},
+        "roident preserved for subscription '$subname' after upgrade");
+}
+

Won't this check miss (and silently pass) if an entry is missing
post-upgrade? It verifies that all entries that exists match the pre
upgrade entries, but it doesn't verify that the list is the same.



pgsql-hackers by date:

Previous
From: Paul A Jungwirth
Date:
Subject: Re: Move FOR PORTION OF checks out of analysis
Next
From: Bharath Rupireddy
Date:
Subject: Re: Report replica identity in pg_publication_tables