Re: SSI and 2PC

Поиск
Список
Период
Сортировка
От Heikki Linnakangas
Тема Re: SSI and 2PC
Дата
Msg-id 4D2CA445.1080700@enterprisedb.com
обсуждение исходный текст
Ответ на Re: SSI and 2PC  (Florian Pflug <fgp@phlo.org>)
Ответы Re: SSI and 2PC
Re: SSI and 2PC
Список pgsql-hackers
On 11.01.2011 20:08, Florian Pflug wrote:
> Unfortunately, it seems that doing things this way will undermine the guarantee
> that retrying a failed SSI transaction won't fail due to the same conflict as
> it did originally. Consider
>
> T1>  BEGIN TRANSACTION ISOLATION SERIALIZABLE
> T1>  SELECT * FROM T
> T1>  UPDATE T ...
> T1>  PREPARE TRANSACTION
>
> T2>  BEGIN TRANSACTION ISOLATION SERIALIZABLE
> T2>  SELECT * FROM T
> T2>  UPDATE T ...
>      ->  Serialization Error
>
> Retrying T2 won't help as long as T1 isn't COMMITTED.

T2 should block until T1 commits. I would be very surprised if it 
doesn't behave like that already. In general, a prepared transaction 
should be treated like an in-progress transaction - it might still abort 
too.

--   Heikki Linnakangas  EnterpriseDB   http://www.enterprisedb.com


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

Предыдущее
От: "Kevin Grittner"
Дата:
Сообщение: Re: SSI and 2PC
Следующее
От: "Kevin Grittner"
Дата:
Сообщение: Re: SSI and 2PC