Re: Fix race condition in pg_get_publication_tables with concurrent DROP TABLE

Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com>

From: Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com>
To: Masahiko Sawada <sawada.mshk@gmail.com>
Cc: shveta malik <shveta.malik@gmail.com>, Ajin Cherian <itsajin@gmail.com>, Bertrand Drouvot <bertranddrouvot.pg@gmail.com>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2026-07-04T05:26:00Z
Lists: pgsql-hackers

Attachments

Hi,

On Tue, Jun 30, 2026 at 10:38 AM Masahiko Sawada <sawada.mshk@gmail.com> wrote:
>
> While changes to pg_get_publication_tables() look good to me,

Thanks for reviewing!

> I think
> the regression tests should be implemented as an isolation test rather
> than a TAP test in 100_bugs.pl as it can be tested without subscribers
> and the isolation test works well for this kind of race condition
> tests.

Agreed. The isolation test avoids the extra publisher start/stop the
TAP version needed, and it's about the same amount of code. Please
find the attached v9 patches.

-- 
Bharath Rupireddy
Amazon Web Services: https://aws.amazon.com