Re: Yet another fast GiST build
От | Heikki Linnakangas |
---|---|
Тема | Re: Yet another fast GiST build |
Дата | |
Msg-id | 422beff9-0e01-9ce6-edb9-c2a2289e8eb9@iki.fi обсуждение исходный текст |
Ответ на | Re: Yet another fast GiST build ("Andrey M. Borodin" <x4mmm@yandex-team.ru>) |
Ответы |
Re: Yet another fast GiST build
|
Список | pgsql-hackers |
On 21/09/2020 12:06, Andrey M. Borodin wrote: >> 21 сент. 2020 г., в 13:45, Heikki Linnakangas <hlinnaka@iki.fi> >> написал(а): >> >> Actually, don't we have a problem with that, even before this >> patch? Even though we set the LSN to the magic GistBuildLSN value >> when we build the index, WAL replay will write the LSN of the >> record instead. That would mess with the LSN-NSN interlock. After >> WAL replay (or in a streaming replica), a scan on the GiST index >> might traverse right-links unnecessarily. > > I think we don't set rightlinks during index build. The new GiST sorting code does not, but the regular insert-based code does. That's a bit questionable in the new code actually. Was that a conscious decision? The right-links are only needed when there are concurrent page splits, so I think it's OK, but the checks for InvalidBlockNumber in gistScanPage() and gistFindPage() have comment "/* sanity check */". Comment changes are needed, at least. - Heikki
В списке pgsql-hackers по дате отправления: