Fix XLogFileReadAnyTLI silently applying divergent WAL from wrong timeline

Edit
ID 6525
Title Fix XLogFileReadAnyTLI silently applying divergent WAL from wrong timeline
CI (CFBot) Summary
Stats (from CFBot) Patch version: v4, Patch count: 1, First patch: +263−0, All patches: +263−0
Tags Bugfix
Created 2026-02-25 08:19:30
Last modified 2026-08-01 00:00:10 (1 month ago)
Latest email 2026-09-18 06:31:59 (2 days ago)
Status
PG20-2 (2026-09-01 – 2026-09-30): Needs review
PG20-1 (2026-07-01 – 2026-07-31): Moved to different CF
PG19-Final (2026-03-01 – 2026-04-09): Moved to different CF
Target version
Authors Andrey Borodin (x4m)
Reviewers Surya Poondla (spoondla), solai v (solaiv) Become reviewer
Committer
Links
Emails
Fix XLogFileReadAnyTLI silently applying divergent WAL from wrong timeline
First at 2026-02-20 13:09:23 by Andrey Borodin <x4mmm at yandex-team.ru>
Latest at 2026-09-18 06:31:59 by solai v <solai.cdac at gmail.com>
Latest attachment (v4-0001-Prevent-archive-recovery-from-reading-divergent-WAL.patch) at 2026-09-04 19:02:33 from Andrey Borodin <x4mmm at yandex-team.ru>
    Attachment (v4-0001-Prevent-archive-recovery-from-reading-divergent-WAL.patch) at 2026-09-04 19:02:33 from Andrey Borodin <x4mmm at yandex-team.ru> (Patch: No)
    Attachment (v3-0001-Prevent-archive-recovery-from-reading-divergent-W.patch) at 2026-08-21 15:39:23 from Andrey Borodin <x4mmm at yandex-team.ru> (Patch: No)
    Attachment (v2-0001-Fix-archive-recovery-falling-back-to-wrong-timeli.patch) at 2026-02-25 13:19:17 from Andrey Borodin <x4mmm at yandex-team.ru> (Patch: Yes)
    Attachment (0001-Fix-archive-recovery-falling-back-to-wrong-timeline-.patch) at 2026-02-20 13:09:23 from Andrey Borodin <x4mmm at yandex-team.ru> (Patch: Yes)
History
When Who What
2026-09-18 04:28:56 solai v (solaiv) Added solaiv as reviewer
2026-09-04 19:32:33 CFbot Patch does not need rebase anymore
2026-08-27 21:55:29 CFbot Patch needs rebase
2026-08-01 00:00:10 CFbot Moved from CF PG20-1 to CF PG20-2
2026-07-09 18:03:16 Surya Poondla (spoondla) Added spoondla as reviewer
2026-06-17 17:53:18 Andrey Borodin (x4m) Moved from CF PG19-Final to CF PG20-1
2026-02-25 08:19:30 Andrey Borodin (x4m) Attached mail thread 85386EF6-16B7-4D62-86BE-526A10F93825@yandex-team.ru
2026-02-25 08:19:30 Andrey Borodin (x4m) Created patch record
Edit