Re: Handle concurrent drop when doing whole database vacuum

From: cca5507 <cca5507(at)qq(dot)com>
To: Bharath Rupireddy <bharath(dot)rupireddyforpostgres(at)gmail(dot)com>, Michael Paquier <michael(at)paquier(dot)xyz>
Cc: Kyotaro Horiguchi <horikyota(dot)ntt(at)gmail(dot)com>, pgsql-hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, suryapoondla4 <suryapoondla4(at)gmail(dot)com>
Subject: Re: Handle concurrent drop when doing whole database vacuum
Date: 2026-06-29 04:58:51
Message-ID: tencent_ADEC9C42E70B236A9B521665B2F1380E3409@qq.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

> > > > 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.
>
> Fixed.

Remove some outdated comments in v7.

--
Regards,
ChangAo Chen

Attachment Content-Type Size
v7-0001-Do-not-check-permissions-in-get_all_vacuum_rels.patch application/octet-stream 3.3 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message surya poondla 2026-06-29 05:01:07 Re: Handle concurrent drop when doing whole database vacuum
Previous Message Bertrand Drouvot 2026-06-29 04:56:11 Re: [PATCH] Change wait_time column of pg_stat_lock to double precision