Re: Is this a problem in GenericXLogFinish()?

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: Is this a problem in GenericXLogFinish()?
Дата
Msg-id CA+TgmoZ3fxKQMw1tUDargbyv2HPpXLNC9YhXsbh37Tp52doWMw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Is this a problem in GenericXLogFinish()?  (Amit Kapila <amit.kapila16@gmail.com>)
Список pgsql-hackers
On Mon, Oct 30, 2023 at 11:15 PM Amit Kapila <amit.kapila16@gmail.com> wrote:
> My understanding is the same. It is possible that my wording is not
> clear. Let me try to clarify again, Michael asked: "do we need the
> cleanup lock on the write buffer even if there are no tuples, and even
> if primary bucket and the write bucket are the same?" My reading of
> his question was do we need a cleanup lock even if the primary bucket
> and write bucket are the same which means the write bucket will be the
> first page in the chain and we need a cleanup lock on it. I think the
> second condition (no tuples) seems irrelevant here as whether that is
> true or false we need a cleanup lock.

Ah, OK, I see now. I missed the fact that, per what Michael wrote, you
were assuming the primary buffer and the write buffer were the same.
In that case I agree, but the whole formulation seems backwards. I
think the clearer way to say this is: we need a cleanup lock on the
primary bucket page no matter what; and we need to write tuples into
the write buffer if there are any tuples to write but not if there
aren't. If the two buffers are the same then the requirements are
added together.

--
Robert Haas
EDB: http://www.enterprisedb.com



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

Предыдущее
От: Robert Haas
Дата:
Сообщение: Re: Requiring recovery.signal or standby.signal when recovering with a backup_label
Следующее
От: vignesh C
Дата:
Сообщение: Re: Intermittent failure with t/003_logical_slots.pl test on windows