Re: logical: fix recomputation required LSN on restart_lsn-only advancement - Mailing list pgsql-hackers

From Álvaro Herrera
Subject Re: logical: fix recomputation required LSN on restart_lsn-only advancement
Date
Msg-id ahoPUr0VVOelhiBa@alvherre.pgsql
Whole thread
In response to logical: fix recomputation required LSN on restart_lsn-only advancement  (Chao Li <li.evan.chao@gmail.com>)
List pgsql-hackers
On 2026-Apr-21, Chao Li wrote:

> While reading logical replication code, I found an issue in
> LogicalConfirmReceivedLocation().
> 
> In LogicalConfirmReceivedLocation(), updated_restart is tracked
> independently from updated_xmin, and the slot is marked dirty and
> saved when either one changed. But after that,
> ReplicationSlotsComputeRequiredLSN() is still only called inside "if
> (updated_xmin)”. 

Have you seen this causing issues in any cases beyond REPACK?  I'm
wondering about your suggestion to backpatch this change:

> Looks like this issue has been there for a long time, so if this
> analysis is correct, it may also be worth back-patching.

If REPACK is the only affected party, then we don't need to care; as
Antonin said, the xmin advances frequently enough in other cases, so it
shouldn't normally be a problem ...

-- 
Álvaro Herrera        Breisgau, Deutschland  —  https://www.EnterpriseDB.com/



pgsql-hackers by date:

Previous
From: Dilip Kumar
Date:
Subject: Re: Proposal: Conflict log history table for Logical Replication
Next
From: Amit Kapila
Date:
Subject: Re: [Patch] Fix check_pub_rdt bypass when origin is set in same ALTER SUBSCRIPTION