RE: [BUG] Unexpected action when publishing partition tables
Zhijie Hou (Fujitsu) <houzj.fnst@fujitsu.com>
From: "houzj.fnst@fujitsu.com" <houzj.fnst@fujitsu.com>
To: vignesh C <vignesh21@gmail.com>
Cc: Amit Kapila <amit.kapila16@gmail.com>, "tanghy.fnst@fujitsu.com" <tanghy.fnst@fujitsu.com>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>, Amit Langote <amitlangote09@gmail.com>, Peter Eisentraut <peter.eisentraut@enterprisedb.com>
Date: 2021-09-16T01:45:13Z
Lists: pgsql-hackers
Attachments
- v3-0001-Made-the-existing-relation-cache-invalidation-an.patch (application/octet-stream) patch v3-0001
- v3-0002-Invalidate-all-partitions.patch (application/octet-stream) patch v3-0002
On Tuesday, September 14, 2021 10:41 PM vignesh C <vignesh21@gmail.com> wrote: > On Tue, Sep 7, 2021 at 11:38 AM houzj.fnst@fujitsu.com <houzj.fnst@fujitsu.com> wrote: > > > > > > Attach new version patches which addressed the comment. > > Thanks for fixing this issue. The bug gets fixed by the patch, I did not find any > issues in my testing. > I just had one minor comment: > > We could clean the table at the end by calling DROP TABLE testpub_parted2: > +-- still fail, because parent's publication replicates updates UPDATE > +testpub_parted2 SET a = 2; > +ERROR: cannot update table "testpub_parted2" because it does not > have a replica identity and publishes updates > +HINT: To enable updating the table, set REPLICA IDENTITY using ALTER > TABLE. > +ALTER PUBLICATION testpub_forparted DROP TABLE testpub_parted; > +-- works again, because update is no longer replicated UPDATE > +testpub_parted2 SET a = 2; Thanks for the comment. Attach new version patches which clean the table at the end. Best regards, Hou zj
Commits
-
Invalidate all partitions for a partitioned table in publication.
- f09a81f1c08f 13.5 landed
- 9eff85932659 14.0 landed
- 4548c76738b3 15.0 landed