> On 16 Jul 2026, at 01:18, Robert Haas <[email protected]> wrote:
> 
> 
> understand Andrey's probable desire to have me review his patch on
> that thread, but I think whatever is going on there is only
> tangentially related to this problem.

Of course I'd like that fix committed too :) But that's not why I'm raising it 
here.

+# The reason for the problem is that when a new primary is promoted, the
+# partial file that ends the old timeline is renamed, giving it a ".partial"
+# suffix, and is not archived. That's not a problem for recovery, because
+# the bytes that appear at the start of that segment will be copied into the
+# first segment on the new timeline, and recovery will read them from there
+# and work just fine.

That only holds when the new timeline's segment is already available. If it 
isn't,
XLogFileReadAnyTLI() falls back to the ancestor's segment and, past the switch 
point,
hands recovery the old timeline's divergent WAL. It's the mirror, on the 
recovery
side, of what your patch fixes for the summarizer.

I'm not asking you to fix XLogFileReadAnyTLI() here. I just don't think the new
comment should claim recovery is unaffected.


Best regards, Andrey Borodin.

Reply via email to