Re: visibility maps

Поиск
Список
Период
Сортировка
От Pavan Deolasee
Тема Re: visibility maps
Дата
Msg-id 2e78013d0812170214y389393fft524adb5d8d31fe17@mail.gmail.com
обсуждение исходный текст
Ответ на Re: visibility maps  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
Ответы Re: visibility maps  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Wed, Dec 17, 2008 at 3:29 PM, Heikki Linnakangas
<heikki.linnakangas@enterprisedb.com> wrote:
>
>
> I don't quite understand this paragraph. If there's any DEAD tuples or
> line-pointers, the all-visible flag can't be set. After an UPDATE or DELETE,
> it indeed takes two vacuums until the bits in the visibility map are set.
>
> Or did you mean that it only works because the prune phase sets the hint
> bits on the tuples? HeapTupleSatisfiesVacuum sets them too, so we're not
> relying on the prune phase to set them.
>

No, I am saying, HOT-prune removes all DEAD tuples from the page (not
the DEAD line pointers though) and that's why you may not need two
vacuums for the visibility bit to set because the first phase of
vacuum would not find any DEAD tuples. Without HOT prune, two vacuums
will be required to set the bit and that would be counter intuitive
because somebody who has just run vacuum on the table would expect the
next vacuum to be no-op if there are no updates/deletes in between.

Thanks,
Pavan

-- 
Pavan Deolasee
EnterpriseDB     http://www.enterprisedb.com


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

Предыдущее
От: Heikki Linnakangas
Дата:
Сообщение: Re: visibility maps
Следующее
От: Zdenek Kotala
Дата:
Сообщение: Re: WIP: pre-upgrade page reservation