Content-Length: 264892 | pFad | http://github.com/postgrespro/postgres/commit/3950e07eb46ebe99331ca82d659269056470f596

CE Avoid race condition in logical replication test · postgrespro/postgres@3950e07 · GitHub
Skip to content

Commit 3950e07

Browse files
Avoid race condition in logical replication test
Wait for slot to become inactive before continuing. Author: Petr Jelinek
1 parent 44654f3 commit 3950e07

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/test/recovery/t/006_logical_decoding.pl

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,11 @@
7878
is($stdout_recv, $expected,
7979
'got same expected output from pg_recvlogical decoding session');
8080

81+
$node_master->poll_query_until('postgres',
82+
"SELECT EXISTS (SELECT 1 FROM pg_replication_slots WHERE slot_name = 'test_slot' AND active_pid IS NULL)"
83+
)
84+
or die "slot never became inactive";
85+
8186
$stdout_recv = $node_master->pg_recvlogical_upto(
8287
'postgres', 'test_slot', $endpos, 10,
8388
'include-xids' => '0',

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/postgrespro/postgres/commit/3950e07eb46ebe99331ca82d659269056470f596

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy