Re: DataChecksumsStateStruct cost_delay fields and locking - Mailing list pgsql-hackers

From Heikki Linnakangas
Subject Re: DataChecksumsStateStruct cost_delay fields and locking
Date
Msg-id d7da8e54-367e-4da6-9f5e-b0c9288be1ef@iki.fi
Whole thread
Responses Re: DataChecksumsStateStruct cost_delay fields and locking
List pgsql-hackers
On 17/06/2026 16:04, Daniel Gustafsson wrote:
> All comments addressed in the attached.

Thanks, LGTM.

> @@ -1533,9 +1532,13 @@ DataChecksumsWorkerMain(Datum arg)
>      /*
>       * Get a list of all temp tables present as we start in this database. We
>       * need to wait until they are all gone until we are done, since we cannot
> -     * access these relations and modify them.
> +     * access these relations and modify them.  For the list of relations to
> +     * process once the temp relations are gone, check if shared catalogs have
> +     * been processed already.
>       */
>      InitialTempTableList = BuildRelationList(true, false);
> +    LWLockAcquire(DataChecksumsWorkerLock, LW_EXCLUSIVE);
> +    process_shared = DataChecksumState->process_shared_catalogs;
>  
>      /*
>       * Enable vacuum cost delay, if any.  While this process isn't doing any

Not new with this patch, but caught my eye now: the double "until" in 
the phrase "We need to wait until they are all gone until we are done" 
sounds a little awkward. I had to read it a few times to parse it right. 
I'd suggest "We need to wait until they are all gone before we exit" or 
something like that.

- Heikki




pgsql-hackers by date:

Previous
From: Nathan Bossart
Date:
Subject: Re: fix prev link in docs
Next
From: Alvaro Herrera
Date:
Subject: Re: Adding REPACK [concurrently]