On Mon, Dec 06, 2021 at 11:24:09PM +0900, Masahiko Sawada wrote:
> On Mon, Dec 6, 2021 at 5:09 PM Michael Paquier <mich...@paquier.xyz> wrote:
>> Shouldn't you check for parsed.origin_lsn instead?  The replication
>> origin is stored there as far as I read EndPrepare().
> 
> Also, looking at PrepareRedoAdd(), we check the replication origin id.
> So I think that it'd be better to check origin_id for consistency.

Okay, this consistency would make sense, then.  Perhaps some comments
should be added to tell that?

>> Commit records check after XACT_XINFO_HAS_ORIGIN, but
>> xact_desc_abort() may include this information for ROLLBACK PREPARED
>> transactions so we could use the same logic as xact_desc_commit() for
>> the abort case, no?
> 
> Good catch! I'll submit an updated patch.

Thanks!
--
Michael

Attachment: signature.asc
Description: PGP signature

Reply via email to