Re: logical decoding and replication of sequences, take 2

Поиск
Список
Период
Сортировка
От Andres Freund
Тема Re: logical decoding and replication of sequences, take 2
Дата
Msg-id 20230111202851.nrqybwypzk4k5bwg@awork3.anarazel.de
обсуждение исходный текст
Ответ на Re: logical decoding and replication of sequences, take 2  (Robert Haas <robertmhaas@gmail.com>)
Ответы Re: logical decoding and replication of sequences, take 2
Список pgsql-hackers
Hi,

On 2023-01-11 15:23:18 -0500, Robert Haas wrote:
> Yeah, I meant if #1 had committed and then #2 started to do its thing.
> I was worried that decoding might reach the nextval operations in
> transaction #2 before it replayed #1.
>
> This worry may be entirely based on me not understanding how this
> actually works. Do we always apply a transaction as soon as we see the
> commit record for it, before decoding any further?

Yes.

Otherwise we'd have a really hard time figuring out the correct historical
snapshot to use for subsequent transactions - they'd have been able to see the
catalog modifications made by the committing transaction.

Greetings,

Andres Freund



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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: Minimal logical decoding on standbys
Следующее
От: Andres Freund
Дата:
Сообщение: Re: Exposing the lock manager's WaitForLockers() to SQL