Re: the big picture for index-only scans

Поиск
Список
Период
Сортировка
От Gokulakannan Somasundaram
Тема Re: the big picture for index-only scans
Дата
Msg-id CAHMh4-Yj2t2X4r_R1+g1EBF3rqL6eJAZX4x-Ku8pwam79GhHVA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: the big picture for index-only scans  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
Ответы Re: the big picture for index-only scans  (Gokulakannan Somasundaram <gokul007@gmail.com>)
Re: the big picture for index-only scans  (Robert Haas <robertmhaas@gmail.com>)
Список pgsql-hackers
On Sat, Aug 20, 2011 at 2:25 AM, Heikki Linnakangas <heikki.linnakangas@enterprisedb.com> wrote:
On 19.08.2011 21:06, Gokulakannan Somasundaram wrote:
If you are following the same design that Heikki put forward, then there is
a problem with it in maintaining the bits in page and the bits in visibility
map in sync, which we have already discussed.

Are you referring to this: http://archives.postgresql.org/pgsql-hackers/2010-02/msg02097.php ? I believe Robert's changes to make the visibility map crash-safe covers that. Clearing the bit in the visibility map now happens within the same critical section as clearing the flag on the heap page and writing th WAL record.

In that case, say a 100 sessions are trying to update records which fall under the 8000*4 heap pages( i assume 2 bits per visibility map - 8 * 1024 * 4 exact) covered by one page of visibility map, won't it make the 99 sessions wait for that visibility map while holding the exclusive lock on the 99 heap pages? 
Are we going to say, that these kind of situations occur very rarely? Or that the loss of scalability in these situations, is worth the performance during the read-heavy workloads?
 
In any case, making a database going through all these extra overheads, while they don't even have any index-only scans!!!  That definitely should be given a thought.

Gokul.

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

Предыдущее
От: Heikki Linnakangas
Дата:
Сообщение: Re: the big picture for index-only scans
Следующее
От: Gokulakannan Somasundaram
Дата:
Сообщение: Re: the big picture for index-only scans