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

Поиск
Список
Период
Сортировка
От Simon Riggs
Тема Re: [HACKERS] logical decoding of two-phase transactions
Дата
Msg-id CANP8+jJGRpczm8L=LQCzuiEG3qHbY1cQB+T4A-cct7xgFmjj9g@mail.gmail.com
обсуждение исходный текст
Ответ на [HACKERS] logical decoding of two-phase transactions  (Stas Kelvich <s.kelvich@postgrespro.ru>)
Ответы Re: [HACKERS] logical decoding of two-phase transactions  (Simon Riggs <simon@2ndquadrant.com>)
Список pgsql-hackers
On 31 December 2016 at 08:36, Stas Kelvich <s.kelvich@postgrespro.ru> wrote:
> Here is resubmission of patch to implement logical decoding of two-phase transactions (instead of treating them
> as usual transaction when commit) [1] I’ve slightly polished things and used test_decoding output plugin as client.

Sounds good.

> General idea quite simple here:
>
> * Write gid along with commit/prepare records in case of 2pc

GID is now variable sized. You seem to have added this to every
commit, not just 2PC

> * Add several routines to decode prepare records in the same way as it already happens in logical decoding.
>
> I’ve also added explicit LOCK statement in test_decoding regression suit to check that it doesn’t break thing.

Please explain that in comments in the patch.

>  If
> somebody can create scenario that will block decoding because of existing dummy backend lock that will be great
> help. Right now all my tests passing (including TAP tests to check recovery of twophase tx in case of failures from
> adjacent mail thread).
>
> If we will agree about current approach than I’m ready to add this stuff to proposed in-core logical replication.
>
> [1] https://www.postgresql.org/message-id/EE7452CA-3C39-4A0E-97EC-17A414972884%40postgrespro.ru

We'll need some measurements about additional WAL space or mem usage
from these approaches. Thanks.

--
Simon Riggs                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services



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

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: [HACKERS] generating fmgr prototypes automatically
Следующее
От: Robert Haas
Дата:
Сообщение: Re: [HACKERS] [sqlsmith] Crash reading pg_stat_activity