RE: Selectively invalidate caches in pgoutput module

Hayato Kuroda (Fujitsu) <kuroda.hayato@fujitsu.com>

From: "Hayato Kuroda (Fujitsu)" <kuroda.hayato@fujitsu.com>
To: 'Amit Kapila' <amit.kapila16@gmail.com>
Cc: "pgsql-hackers@lists.postgresql.org" <pgsql-hackers@lists.postgresql.org>, "ShlokKumar.Kyal@fujitsu.com" <ShlokKumar.Kyal@fujitsu.com>, "Zhijie Hou (Fujitsu)" <houzj.fnst@fujitsu.com>, Masahiko Sawada <sawada.mshk@gmail.com>
Date: 2025-03-12T12:15:58Z
Lists: pgsql-hackers

Attachments

Dear Amit,

> Thanks, the patch looks mostly good to me. I have made few cosmetic
> changes in the attached and combined both the patches.

Thanks, it looks good to me.

> The existing
> Alter Publication ... Rename tests don't test invalidations arising
> from that command. As this patch changes that code path, it would be
> good to add a few tests for the same. We can add one for individual
> relations and another for ALL Tables publication.

I created new patch which adds a test code. I added in 007_ddl.pl, but I feel
it is OK to introduce new test file. How do you think?

Best regards,
Hayato Kuroda
FUJITSU LIMITED

Commits

  1. Avoid invalidating all RelationSyncCache entries on publication rename.

  2. Avoid invalidating all RelationSyncCache entries on publication change.