Re: Update on true serializable techniques in MVCC

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: Update on true serializable techniques in MVCC
Дата
Msg-id 603c8f070912160736v1f12acaeif7d9096190c792b7@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Update on true serializable techniques in MVCC  (Andres Freund <andres@anarazel.de>)
Ответы Re: Update on true serializable techniques in MVCC  (Alvaro Herrera <alvherre@commandprompt.com>)
Список pgsql-hackers
On Wed, Dec 16, 2009 at 10:29 AM, Andres Freund <andres@anarazel.de> wrote:
> On Wednesday 16 December 2009 16:24:42 Robert Haas wrote:
>> >   Inserts and deletes follow the same protocol, obtaining an exclusive
>> >   lock on the row after the one being inserted or deleted. The result
>> >   of this locking protocol is that a range scan prevents concurrent
>> >   inserts or delete within the range of the scan, and vice versa.
>> >
>> > That sounds like it should actually work.
>>
>> Only if you can guarantee that the database will access the rows using
>> some particular index.  If it gets to the data some other way it might
>> accidentally circumvent the lock.  That's kind of a killer in terms of
>> making this work for PostgreSQL.
> Isnt the whole topic only relevant for writing access? There you have to
> access the index anyway.

Yeah, I guess you have to insert the new tuple.  I guess while you
were at it you might check whether the next tuple is locked...

...Robert


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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: Update on true serializable techniques in MVCC
Следующее
От: Marko Kreen
Дата:
Сообщение: Re: Patch: Remove gcc dependency in definition of inline functions