Re: Handle concurrent drop when doing whole database vacuum - Mailing list pgsql-hackers

From Bharath Rupireddy
Subject Re: Handle concurrent drop when doing whole database vacuum
Date
Msg-id CALj2ACUrT2XG1SYUnV3S5dZSdT=893Rpfzqc4dGCtwx8MHskFQ@mail.gmail.com
Whole thread
In response to Re: Handle concurrent drop when doing whole database vacuum  (Michael Paquier <michael@paquier.xyz>)
Responses Re: Handle concurrent drop when doing whole database vacuum
List pgsql-hackers
Hi,

On Sun, Jun 28, 2026 at 5:13 PM Michael Paquier <michael@paquier.xyz> wrote:
>
> On Sat, Jun 27, 2026 at 12:32:42PM -0700, Bharath Rupireddy wrote:
> > I would have considered adding an
> > Assert(CheckRelationOidLockedByMe(relid, AccessShareLock, true))
> > instead of the note, but that seems like overkill to me. So, I'm fine
> > without it.
>
> An assertion is impossible to miss, acts as self-documentation and it
> is not a performance critical path.  A note at the top of the function
> could be easily missed.  I don't see why the note needs to mention the
> case of a concurrent drop.  So let's just keep the runtime check, then
> drop the note, finally call it a day.

Works for me. Thanks.

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



pgsql-hackers by date:

Previous
From: Henson Choi
Date:
Subject: Re: Heads Up: cirrus-ci is shutting down June 1st
Next
From: Michael Paquier
Date:
Subject: Re: [PATCH] doc: clarify pg_stat_lock.fastpath_exceeded scope