Fix WAL data loss on instance hibernation/shutdown (#10341) by abhayclasher · Pull Request #10352 · cloudnative-pg/cloudnative-pg
This PR changes 0-9 lines, ignoring generated files.
label
Mar 22, 2026When a CNPG instance is shut down (e.g. during hibernation), the last WAL segments might remain on local storage and not be archived to the object store. This is because ArchiveAllReadyWALs() was only triggered during switchover/demotion. This commit ensures that ArchiveAllReadyWALs() is also called after a successful smart/fast shutdown in the lifecycle loop, preventing data loss of the final WAL segments. References: cloudnative-pg#10341 Signed-off-by: Abhay Kumar <abhaypro.cloud@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters