Re: pgsql: Get rid of the dedicated latch for signaling the startup process
| От | Heikki Linnakangas |
|---|---|
| Тема | Re: pgsql: Get rid of the dedicated latch for signaling the startup process |
| Дата | |
| Msg-id | b3265f23-f47c-6ab1-e0e7-2df0c3e4e9e1@iki.fi обсуждение исходный текст |
| Ответ на | Re: pgsql: Get rid of the dedicated latch for signaling the startup process (Fujii Masao <masao.fujii@oss.nttdata.com>) |
| Ответы |
Re: pgsql: Get rid of the dedicated latch for signaling the startup process
|
| Список | pgsql-committers |
On 04/11/2020 14:03, Fujii Masao wrote: >> I'm thinking to remove the following code to fix this issue. Thought? >> >> /* >> * We don't need the latch anymore. It's not strictly necessary to reset >> * it to NULL, but let's do it for the sake of tidiness. >> */ >> if (ArchiveRecoveryRequested) >> XLogCtl->recoveryWakeupLatch = NULL; That should work, but it seems a bit sloppy to leave it pointing to a latch that belongs to a random process though. > Or ISTM that WakeupRecovery() should set the latch only when the latch > has not been reset to NULL yet. Got to be careful with race conditions, if the latch is set to NULL at the same time that WakeupRecovery() is called. - Heikki
В списке pgsql-committers по дате отправления: