From: Michael Paquier <michael@paquier.xyz>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Thomas Munro <thomas.munro@gmail.com>
Cc: pgsql-committers@lists.postgresql.org
Subject: Re: pgsql: Use condition variables to wait for checkpoints.
Date: Thu, 14 Mar 2019 09:33:42 +0900
Message-ID: <20190314003342.GD3493@paquier.xyz> (raw)
In-Reply-To: <24619.1552519537@sss.pgh.pa.us>
References: <E1h4BxT-0007ae-UP@gemulon.postgresql.org>
<CA+hUKGLUpqG52xtriUz5RpmeKPoEfNxNc-CginG+Cx+X2-Ycew@mail.gmail.com>
<24619.1552519537@sss.pgh.pa.us>
On Wed, Mar 13, 2019 at 07:25:37PM -0400, Tom Lane wrote:
> and if you look at the test script, there is no sort of wait for the
> creation of "test1" to propagate to the slave before we try to query
> it on the slave. We'd have seen this fall over soon enough with or
> without your commit.
Oops, sorry. I was monitoring the buildfarm yesterday and did not
notice any failures. The attached should fix the problem. Does that
look fine?
--
Michael
Attachments:recoveryminlsn-tap-fix.patch (text/x-diff, 704B) downloaddiff --git a/src/test/recovery/t/016_min_consistency.pl b/src/test/recovery/t/016_min_consistency.plindex 8f1a89c2d3..90a270650d 100644--- a/src/test/recovery/t/016_min_consistency.pl+++ b/src/test/recovery/t/016_min_consistency.pl@@ -97,6 +97,10 @@ INSERT INTO test1 SELECT generate_series(1, 10000);");
$primary->safe_psql('postgres', 'CHECKPOINT;');
$primary->safe_psql('postgres', 'UPDATE test1 SET a = a + 1;');
+# Wait for table creation to happen on the standby.+$primary->wait_for_catchup($standby, 'replay',+ $primary->lsn('insert'));+
# Fill in the standby's shared buffers with the data filled in
# previously.
$standby->safe_psql('postgres', 'SELECT count(*) FROM test1;');
signature.asc (application/pgp-signature, 832B) download
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: michael@paquier.xyz, tgl@sss.pgh.pa.us, thomas.munro@gmail.com
Subject: Re: pgsql: Use condition variables to wait for checkpoints.
In-Reply-To: <20190314003342.GD3493@paquier.xyz>
References: <E1h4BxT-0007ae-UP@gemulon.postgresql.org> <CA+hUKGLUpqG52xtriUz5RpmeKPoEfNxNc-CginG+Cx+X2-Ycew@mail.gmail.com> <24619.1552519537@sss.pgh.pa.us> <20190314003342.GD3493@paquier.xyz>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox