RE: locking [user] catalog tables vs 2pc vs logical rep

From: "osumi(dot)takamichi(at)fujitsu(dot)com" <osumi(dot)takamichi(at)fujitsu(dot)com>
To: 'Simon Riggs' <simon(dot)riggs(at)enterprisedb(dot)com>, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>
Cc: vignesh C <vignesh21(at)gmail(dot)com>, Peter Smith <smithpb2250(at)gmail(dot)com>, Andres Freund <andres(at)anarazel(dot)de>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>, Markus Wanner <markus(dot)wanner(at)enterprisedb(dot)com>
Subject: RE: locking [user] catalog tables vs 2pc vs logical rep
Date: 2021-06-18 08:55:17
Message-ID: OSBPR01MB48885FDD9607279FB6C73E4CED0D9@OSBPR01MB4888.jpnprd01.prod.outlook.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Friday, June 18, 2021 11:41 AM osumi(dot)takamichi(at)fujitsu(dot)com <osumi(dot)takamichi(at)fujitsu(dot)com> wrote:
> On Thursday, June 17, 2021 10:34 PM Simon Riggs
> <simon(dot)riggs(at)enterprisedb(dot)com> wrote:
> > On Thu, Jun 17, 2021 at 12:57 PM Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>
> > wrote:
> > > On Thu, Jun 17, 2021 at 4:27 PM Amit Kapila
> > > <amit(dot)kapila16(at)gmail(dot)com>
> > wrote:
> > > >
> > > > On Thu, Jun 17, 2021 at 8:41 AM osumi(dot)takamichi(at)fujitsu(dot)com
> > > > <osumi(dot)takamichi(at)fujitsu(dot)com> wrote:
> > > >
> > > > Pushed!
> > > >
> > > [Responding to Simon's comments]
> > >
> > > > If LOCK and TRUNCATE is advised against on all user catalog
> > > > tables, why would CLUSTER only apply to pg_class? Surely its
> > > > locking level is the
> > same as LOCK?
> > > >
> > >
> > > Cluster will also apply to all user catalog tables. I think we can
> > > extend it slightly as we have mentioned for Lock.
> >
> > OK, good.
> >
> > > > The use of "[user]" isn't fully explained, so it might not be
> > > > clear that this applies to both Postgres catalog tables and any
> > > > user tables that
> > have been nominated as catalogs. Probably worth linking to the
> "Capabilities"
> > section to explain.
> > > >
> > >
> > > Sounds reasonable.
> Simon, I appreciate your suggestions and yes, if the user catalog table is
> referenced by the output plugin, it can be another cause of the deadlock.
>
> I'm going to post the patch for the those two changes, accordingly.
Hi, I've made the patch-set to cover the discussion above for all-supported versions.
Please have a look at those.

Best Regards,
Takamichi Osumi

Attachment Content-Type Size
HEAD_extend_logical_decoding_caveats_in_sync_mode_v01.patch application/octet-stream 1.4 KB
PG10_extend_logical_decoding_caveats_in_sync_mode_v01.patch application/octet-stream 1.4 KB
PG11_extend_logical_decoding_caveats_in_sync_mode_v01.patch application/octet-stream 1.4 KB
PG12_extend_logical_decoding_caveats_in_sync_mode_v01.patch application/octet-stream 1.4 KB
PG13_extend_logical_decoding_caveats_in_sync_mode_v01.patch application/octet-stream 1.4 KB
PG96_extend_logical_decoding_caveats_in_sync_mode_v01.patch application/octet-stream 1.4 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Fujii Masao 2021-06-18 09:18:59 Re: fdatasync performance problem with large number of DB files
Previous Message Heikki Linnakangas 2021-06-18 08:31:00 Re: [PoC] Federated Authn/z with OAUTHBEARER