Re: lazy detoasting

Поиск
Список
Период
Сортировка
От Chapman Flack
Тема Re: lazy detoasting
Дата
Msg-id 8ca78589-734b-f904-1cc5-007eeb5d4737@anastigmatix.net
обсуждение исходный текст
Ответ на Re: lazy detoasting  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On 04/11/2018 03:04 PM, Tom Lane wrote:
> Chapman Flack <chap@anastigmatix.net> writes:
>> that it might *not* be sufficient to find an applicable snapshot at
>> the time of constructing the object, and register that snapshot
>> on TopTransactionResourceOwner?
> 
> The problem is to know which snapshot is applicable; if the transaction
> has more than one, you don't know which was used to read the row of
> interest.  I suppose you could be conservative and use the oldest one,
> if snapmgr lets you find that.

There does seem to be GetOldestSnapshot(), returning
older( oldest on active stack, oldest on registered heap ).

And it seems to be the very thing called by tuptoaster itself,
right after the comment "since we don't know which one to use,
just use the oldest one".

-Chap


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: lazy detoasting
Следующее
От: Teodor Sigaev
Дата:
Сообщение: Re: Partitioned tables and covering indexes