From: | Nathan Bossart <nathandbossart(at)gmail(dot)com> |
---|---|
To: | Michael Paquier <michael(at)paquier(dot)xyz> |
Cc: | Andres Freund <andres(at)anarazel(dot)de>, Jacob Speidel <jacob(at)extrahop(dot)com>, Will Mortensen <will(at)extrahop(dot)com>, pgsql-bugs(at)lists(dot)postgresql(dot)org |
Subject: | Re: BUG #17973: Reinit of pgstats entry for dropped DB can break autovacuum daemon |
Date: | 2023-09-02 15:21:34 |
Message-ID: | 20230902152134.GA3320738@nathanxps13 |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
On Sat, Sep 02, 2023 at 09:08:22AM +0900, Michael Paquier wrote:
> On Fri, Sep 01, 2023 at 08:20:24AM -0700, Nathan Bossart wrote:
>> Something along those lines seems fine to me. FWIW this is what I had in
>> my head:
>>
>> It is important that MyDatabaseId only be set once we are sure that the
>> target database can no longer be concurrently dropped or renamed. Some
>> code depends on this. For example, without this guarantee,
>> pgstat_update_dbstats() could create entries for databases that were
>> just dropped, which will lead to problems down the road.
>
> I'm mostly OK with this formulation as well, but without the second
> sentence and adding as extra that pgstat_update_dbstats() could be
> specifically called in the shutdown callback of the shared statistics.
WFM
--
Nathan Bossart
Amazon Web Services: https://aws.amazon.com
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Paquier | 2023-09-02 23:42:55 | Re: BUG #17928: Standby fails to decode WAL on termination of primary |
Previous Message | Alexander Lakhin | 2023-09-02 13:00:00 | Re: BUG #17893: Assert failed in heap_update()/_delete() when FK modiified by RI trigger in non-read-committed xact |