pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Jeff Davis <pgsql@j-davis.com>
To: Dilip Kumar <dilipbalaut@gmail.com>
To: Amit Kapila <amit.kapila16@gmail.com>
Cc: Noah Misch <noah@leadboat.com>
Cc: akapila@postgresql.org
Cc: nisha.moond412@gmail.com
Cc: pgsql-hackers@postgresql.org
Subject: Re: REASSIGN OWNED vs. relisshared dep on !relisshared
Date: Tue, 14 Jul 2026 13:50:00 -0700
Message-ID: <48531fdd144b17fa10b02adae33705de3ada8ea3.camel@j-davis.com> (raw)
In-Reply-To: <CAFiTN-u1ZQge4yCAhhbZ7EdwVrG3MeQH_jbaj2WXgoSYzF0bXQ@mail.gmail.com>
References: <20260710192533.4f.noahmisch@microsoft.com>
	<f629d0d3f74413e48a53bdf5b334b215c68545fb.camel@j-davis.com>
	<CAA4eK1Lsv61zLoQ7Pzb6AJcbLOAf7BV=LLYeusUpG_wGV=QStA@mail.gmail.com>
	<CAFiTN-u1ZQge4yCAhhbZ7EdwVrG3MeQH_jbaj2WXgoSYzF0bXQ@mail.gmail.com>

On Mon, 2026-07-13 at 17:04 +0530, Dilip Kumar wrote:
> PFA a patch for skipping subscriptions belonging to different
> databases.

I suggest we add a few checks (or asserts) that subdbid==MyDatabaseId
when reading pg_subscription from anywhere other than the launcher.

Also, the REASSIGN OWNED path goes through
AlterSubscriptionOwner_oid(), whereas both the REASSIGN OWNED and ALTER
SUBSCRIPTION ... OWNER TO paths go through
AlterSubscriptionOwner_internal(). It would be more clear to add the
skipping logic in the former and an assert in the latter.

Other than that, LGTM.

We can also reconsider how we handle dependencies to address Noah's
concern, but this patch is good regardless.

Regards,
	Jeff Davis







view thread (15+ messages)  latest in thread

Message-ID: <48531fdd144b17fa10b02adae33705de3ada8ea3.camel@j-davis.com>
Permalink:  ../48531fdd144b17fa10b02adae33705de3ada8ea3.camel@j-davis.com/
Also on:    postgresql.org/message-id/48531fdd144b17fa10b02adae33705de3ada8ea3.camel@j-davis.com

 · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-hackers@postgresql.org
  Cc: pgsql@j-davis.com, dilipbalaut@gmail.com, amit.kapila16@gmail.com, noah@leadboat.com, akapila@postgresql.org, nisha.moond412@gmail.com
  Subject: Re: REASSIGN OWNED vs. relisshared dep on !relisshared
  In-Reply-To: <48531fdd144b17fa10b02adae33705de3ada8ea3.camel@j-davis.com>
  References: <20260710192533.4f.noahmisch@microsoft.com> <f629d0d3f74413e48a53bdf5b334b215c68545fb.camel@j-davis.com> <CAA4eK1Lsv61zLoQ7Pzb6AJcbLOAf7BV=LLYeusUpG_wGV=QStA@mail.gmail.com> <CAFiTN-u1ZQge4yCAhhbZ7EdwVrG3MeQH_jbaj2WXgoSYzF0bXQ@mail.gmail.com> <48531fdd144b17fa10b02adae33705de3ada8ea3.camel@j-davis.com>

* 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