pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Amit Kapila <amit.kapila16@gmail.com>
Cc: Dilip Kumar <dilipbalaut@gmail.com>
Cc: vignesh C <vignesh21@gmail.com>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Subject: Re: Add an option to skip loading missing publication to avoid logical replication failure
Date: Wed, 30 Apr 2025 01:52:13 -0400
Message-ID: <1230066.1745992333@sss.pgh.pa.us> (raw)
In-Reply-To: <CAA4eK1KQk=m_qiXTXV6jVKQNXps4QiCkaioPw7yKvZbGfzSmhQ@mail.gmail.com>
References: <CALDaNm0-n8FGAorM+bTxkzn+AOUyx5=L_XmnvOP6T24+-NcBKg@mail.gmail.com>
	<CAA4eK1+gaEyYJpsGZktfXptU4gbLcwbzFTC0TBZc1UY2SBPydw@mail.gmail.com>
	<CALDaNm2VTjKe8mQsTXFvrbgzcSO4OiuyOdw4VDBK_Ntn=ay-bQ@mail.gmail.com>
	<CAA4eK1+37NhZg+q_UdX6Bfm1ikfoZPZaS0nqPY6xtMNs4BPQnw@mail.gmail.com>
	<CALDaNm13A+KyNu47YMyu+tL4XeombTHzZt3fpD1QLxh_Mtw+WQ@mail.gmail.com>
	<CALDaNm1Lg1YOtY+Sy2his=ikHsQYYQ1pWN620QiBZDBdbsjMHw@mail.gmail.com>
	<CAA4eK1LSOUXoH+gY1OikbHajxpgbZJqs=jfYGDmckuWWXzcLMQ@mail.gmail.com>
	<CALDaNm2Xkm1M-ik2RLJZ9rMhW2zW2GRLL6ePyZJbXcAjOVwzXg@mail.gmail.com>
	<CALDaNm3Ub=T1c78kDF3y5Wcna3WrzoiEeVL8_atbSFSiVhj8FQ@mail.gmail.com>
	<CAA4eK1JF1VQftiLVwt9QbCeR956Xg8fTsfdm4tnhw=J2_jUWRg@mail.gmail.com>
	<CALDaNm0T4uP0BTQHAzsmw3EtCoq=-y4Ryww9PZTrqiZeyA80XQ@mail.gmail.com>
	<CAFiTN-sAbD1G09bn1EPh4EgEjtqxBdGaSxKYhVCBEQZwgXgdmg@mail.gmail.com>
	<CALDaNm3HYP5WJLV9cKWEXuGgWYSLFOs-=u0qf5OD4Zyb87=6gw@mail.gmail.com>
	<CAFiTN-tnDOhVdKvDR9z3+z3B+dNQFs10e48OgAdRsC9sJXqs0g@mail.gmail.com>
	<CALDaNm2gf! sxQL7VrurNnJffCBcuyrZQ1LXDOhf9FY57n8=8cVw@mail.gmail.com>
	<CAFiTN-u1gKoTau54q=P+N9i8rVwAq4hjVXv6mOkxM_EiqZDMbg@mail.gmail.com>
	<CAA4eK1L-4c2+v7NZB4jWDwtN-VT+UKAm9Vp2dzO2Tyg0HTJvbQ@mail.gmail.com>
	<CAFiTN-v56-ad_OdrMCqgjZbAdUop9syt+J9KiHBsX5QJxPUuHA@mail.gmail.com>
	<CAA4eK1KQk=m_qiXTXV6jVKQNXps4QiCkaioPw7yKvZbGfzSmhQ@mail.gmail.com>

Amit Kapila <amit.kapila16@gmail.com> writes:
> Thanks, Dilip and Sawada-San, for the inputs, and Vignesh for the
> patch. I have pushed the change.

Xuneng Zhou pointed out on Discord that the test case added by
7c99dc587 has caused repeated failures in CI --- though oddly,
it's not failed in the buildfarm so far as I can find.  The
failures look like

timed out waiting for match: (?^:WARNING: ( [A-Z0-9]+:)? skipped loading publication: tap_pub_3) at /tmp/cirrus-ci-build/src/test/subscription/t/024_add_drop_pub.pl line 103.

I suspect that what is happening is that the "skipped loading
publication" message comes out sooner than the 024 test script
expects, and thus that it could be fixed by moving the
"my $offset = -s $node_publisher->logfile;" line to be just
before the ALTER SUBSCRIPTION command instead of just after it.
Because the "skipped" message is from LoadPublications() which
is fundamentally invoked as a result of cache flushes, it's
hardly astonishing that its timing would be erratic.

However, I can't really prove this because I've been unable
to reproduce the failure locally, except by moving the
"my $offset" assignment further down which is surely cheating.

Thoughts?

			regards, tom lane





view thread (48+ messages)  latest in thread

Message-ID: <1230066.1745992333@sss.pgh.pa.us>
Permalink:  ../1230066.1745992333@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/1230066.1745992333@sss.pgh.pa.us

 · 

reply

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 using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: tgl@sss.pgh.pa.us, amit.kapila16@gmail.com, dilipbalaut@gmail.com, vignesh21@gmail.com, pgsql-hackers@lists.postgresql.org
  Subject: Re: Add an option to skip loading missing publication to avoid logical replication failure
  In-Reply-To: <1230066.1745992333@sss.pgh.pa.us>

* 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