Re: recovery_min_apply_delay in archive recovery causes assertionfailure in latch

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: recovery_min_apply_delay in archive recovery causes assertionfailure in latch
Дата
Msg-id 20190930034241.GG2888@paquier.xyz
обсуждение исходный текст
Ответ на recovery_min_apply_delay in archive recovery causes assertion failurein latch  (Fujii Masao <masao.fujii@gmail.com>)
Ответы Re: recovery_min_apply_delay in archive recovery causes assertionfailure in latch  (Fujii Masao <masao.fujii@gmail.com>)
Список pgsql-hackers
On Mon, Sep 30, 2019 at 12:49:03AM +0900, Fujii Masao wrote:
> Attached patch fixes this issue by making archive recovery always ignore
> recovery_min_apply_delay. This change is OK because
> recovery_min_apply_delay was introduced for standby mode, I think.
>
> This issue is not new in v12. I observed that the issue was reproduced
> in v11. So the back-patch is necessary.

I have not directly tested, but from a lookup at the code I think
that you are right.  Perhaps we'd want more safeguards in
WaitForWALToBecomeAvailable(), like an assert within the
XLOG_FROM_STREAM part similar to the check you are adding?  My point
is that we should switch to XLOG_FROM_STREAM only if we are in standby
mode, and that's the only place where the startup process looks at
recoveryWakeupLatch.
--
Michael

Вложения

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Amit Langote
Дата:
Сообщение: Re: default partitions can be partitioned and have default partitions?
Следующее
От: Masahiko Sawada
Дата:
Сообщение: Re: pg_wal/RECOVERYHISTORY file remains after archive recovery