Re: [HACKERS] logical decoding of two-phase transactions

Поиск
Список
Период
Сортировка
От Stas Kelvich
Тема Re: [HACKERS] logical decoding of two-phase transactions
Дата
Msg-id 3477E635-F590-4432-BD20-C59142B65CD3@postgrespro.ru
обсуждение исходный текст
Ответ на Re: [HACKERS] logical decoding of two-phase transactions  (Craig Ringer <craig@2ndquadrant.com>)
Ответы Re: [HACKERS] logical decoding of two-phase transactions  (Craig Ringer <craig@2ndquadrant.com>)
Список pgsql-hackers
> On 26 Jan 2017, at 12:51, Craig Ringer <craig@2ndquadrant.com> wrote:
>
> * Tracking xid/gid map in memory also doesn’t help much — if server reboots between prepare
> and commit we’ll lose that mapping.
>
> Er what? That's why I suggested using the prepared xacts shmem state. It's persistent as you know from your work on
preparedtransaction files. It has all the required info. 

Imagine following scenario:

1. PREPARE happend
2. PREPARE decoded and sent where it should be sent
3. We got all responses from participating nodes and issuing COMMIT/ABORT
4. COMMIT/ABORT decoded and sent

After step 3 there is no more memory state associated with that prepared tx, so if will fail
between 3 and 4 then we can’t know GID unless we wrote it commit record (or table).

--
Stas Kelvich
Postgres Professional: http://www.postgrespro.com
The Russian Postgres Company





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

Предыдущее
От: Kyotaro HORIGUCHI
Дата:
Сообщение: Re: [HACKERS] multivariate statistics (v19)
Следующее
От: David Rowley
Дата:
Сообщение: Re: [HACKERS] Performance improvement for joins where outer side is unique