Re: Re: [COMMITTERS] pgsql: Augment WAL records for btree delete with GetOldestXmin() to

Поиск
Список
Период
Сортировка
От Simon Riggs
Тема Re: Re: [COMMITTERS] pgsql: Augment WAL records for btree delete with GetOldestXmin() to
Дата
Msg-id 1269633600.3684.1170.camel@ebony
обсуждение исходный текст
Ответ на Re: Re: [COMMITTERS] pgsql: Augment WAL records for btree delete with GetOldestXmin() to  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
Ответы Re: Re: [COMMITTERS] pgsql: Augment WAL records for btree delete with GetOldestXmin() to  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Sun, 2010-01-31 at 23:43 +0200, Heikki Linnakangas wrote:

> When replaying the deletion record, the standby could look at all the
> heap tuples whose index pointers are being removed, to see which one
> was newest.

Long after coding this, I now realise this really is a dumb-ass idea.

There is no spoon. The index tuples did once point at valid heap tuples.
1. heap tuples are deleted
2. heap tuples become dead
3. index tuples can now be marked killed
4. index tuples removed
Heap tuples can be removed at step 2, index tuples can't be removed
until step 4. so the dead index tuples can't be followed reliably to
read the xids. They might be the correct ones, might not, and no way to
tell.

So that puts this back to exactly the place we were on 31 Jan:

On Sun, 2010-01-31 at 17:10 -0500, Tom Lane wrote:
> We can always put it back later if nothing better gets
> implemented.

So, barring huge injections of insight, I'll be putting back the
generation of OldestXmin() into the btree delete path.

-- Simon Riggs           www.2ndQuadrant.com



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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: More idle thoughts
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Re: [COMMITTERS] pgsql: Augment WAL records for btree delete with GetOldestXmin() to