Re: Rome university

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: Rome university
Дата
Msg-id 20060502214837.GB18026@surnet.cl
обсуждение исходный текст
Ответ на Rome university  (letizia leo <letizia_leo@yahoo.it>)
Список pgsql-hackers
letizia leo wrote:

> and the doubt is the following: how is it possible that -line 144- Xmin 
> is the current transaction ( i.e. it has created this tuple, it is 
> holding an exclusive lock on it since it has not committed yet) and 
> that 
> -line 149- there is a different (?) transaction that is also locking 
> the 
> tuple (HEAP_IS_LOCKED=(HEAP_XMAX_EXCL_LOCK||HEAP_XMAX_SHARED_LOCK) )? 
> Unless we are missing something, this situation is possible exclusively 
> in case the XMAX transaction is a subtransaction of XMIN, which can 
> access the tuple despite the exclusive lock held by XMIN.

Exactly.

> This seems correct according to the comment in line 154, which refers
> to a "subtransaction".

It is correct.

> Are we understanding correctly what this code is doing and the related 
> underlying MVCC mechanisms?

Can't say, but that part at least you got right :-)

-- 
Alvaro Herrera                                http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support


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

Предыдущее
От: letizia leo
Дата:
Сообщение: Rome university
Следующее
От: Martijn van Oosterhout
Дата:
Сообщение: Re: Rome university