Re: [HACKERS] More replication race conditions - Mailing list pgsql-hackers

From Michael Paquier
Subject Re: [HACKERS] More replication race conditions
Date
Msg-id CAB7nPqTmbZWGBvVr0YYi0fsiN1tB48YAL_s5dgk0K73dCPC6rg@mail.gmail.com
Whole thread Raw
In response to Re: [HACKERS] More replication race conditions  (Petr Jelinek <petr.jelinek@2ndquadrant.com>)
Responses Re: [HACKERS] More replication race conditions  (Petr Jelinek <petr.jelinek@2ndquadrant.com>)
List pgsql-hackers
On Sun, Aug 27, 2017 at 6:32 PM, Petr Jelinek
<petr.jelinek@2ndquadrant.com> wrote:
> Attached should fix this.

+$node_master->poll_query_until('postgres',
+"SELECT EXISTS (SELECT 1 FROM pg_replication_slots WHERE slot_name =
'test_slot' AND active_pid IS NULL)"
+)
+  or die "slot never became inactive";
+$stdout_recv = $node_master->pg_recvlogical_upto(
I am wondering if a similar check should actually go into
pg_recvlogical_upto() instead. I tend to think that we've learned
things the hard way with 3043c1dd and such.
-- 
Michael



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [HACKERS] More replication race conditions
Next
From: Michael Paquier
Date:
Subject: Re: [HACKERS] More replication race conditions