Re: Proposal: New LWLockmode LW_OWNER

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Proposal: New LWLockmode LW_OWNER
Дата
Msg-id 27295.1212775653@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Proposal: New LWLockmode LW_OWNER  ("Jignesh K. Shah" <J.K.Shah@Sun.COM>)
Ответы Re: Proposal: New LWLockmode LW_OWNER  ("Jignesh K. Shah" <J.K.Shah@Sun.COM>)
Список pgsql-hackers
"Jignesh K. Shah" <J.K.Shah@Sun.COM> writes:
> Tom Lane wrote:
>> This seems rather crazy, and you haven't actually given a single
>> convincing use-case.

> One area that I find it useful is where it will be useful is in 
> ProcArrayEndTransaction where it uses exclusive to update  proc array 
> structure where right now it uses EXCLUSIVE and most commit transactions 
> are updating their own proc array structure this lock semantic can be 
> useful..

That is exactly a place where you CAN'T use this, because it will break
transactional semantics, specifically serialization of commits relative
to snapshots.  See all the discussions around the last refactoring of
ProcArray locking, and particularly the summary in
src/backend/access/transam/README.
        regards, tom lane


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

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: Proposal: New LWLockmode LW_OWNER
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Proposal: New LWLockmode LW_OWNER