Re: Code comment change

Поиск
Список
Период
Сортировка
От Peter Geoghegan
Тема Re: Code comment change
Дата
Msg-id CAH2-WzmA2H+rL-xxF5o6QhMD+9x6cJTnz2Mr3Li_pbPBmqoTBQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Code comment change  (Thomas Munro <thomas.munro@gmail.com>)
Ответы Re: Code comment change  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Sun, Jun 23, 2019 at 3:36 AM Thomas Munro <thomas.munro@gmail.com> wrote:
> Pushed.  Thanks!

I wonder what the comment is supposed to mean.

I think that it's addressing the situation prior to commit 70508ba7aed
in 2003, which was the point when the "fast" root concept was
introduced. Prior to that commit, there was only what we would now
call a true root, and _bt_getroot() had to loop to make sure that it
reliably found it without deadlocking, while dealing with concurrent
splits. This was necessary because the old design also involved
maintaining a pointer to each page's parent in each page, which sounds
like a seriously bad approach to me.

I think that the whole sentence about "the standard class of race
conditions" should go. There is no more dance. Nothing in
_bt_getroot() is surprising to me. The other comments explain things
comprehensively.

-- 
Peter Geoghegan



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

Предыдущее
От: Michael Meskes
Дата:
Сообщение: Re: [PATCH] memory leak in ecpglib
Следующее
От: Michael Meskes
Дата:
Сообщение: Re: Bug: ECPG: Cannot use CREATE AS EXECUTE statemnt