Files
velero/pkg/exposer
Tiger Kaovilai eff2522eac Fix generic CSI changeID retrieval and honor snapshot class deletion policy
Two defects in the CSI snapshot exposer, both of which make every CBT
incremental silently degrade to a full backup on non-vSphere drivers.

1. getCBTInfo read the changeID from the freshly-created backup VSC's
   status, which is populated asynchronously and is therefore usually
   empty at that point. The handle is already present in the spec, so
   fall back to vsc.Spec.Source.SnapshotHandle. vSphere is unaffected --
   it takes the VSphereCNSChangeIDAnno branch and never reads the VSC
   handle -- so this affects every other CSI driver.

2. createBackupVSC hardcoded DeletionPolicy: Delete, so the physical
   snapshot was removed when the backup completed. Case-2 storage such
   as Ceph RBD requires the base snapshot to survive for the next
   GetMetadataDelta call, and the block-data-mover design specifies a
   RetainSnapshot volume-policy parameter that was never implemented.
   Inherit the source snapshot class's deletion policy instead, and
   clean up the backup VSC object in CleanUp.

Adds TestCreateBackupVSCDeletionPolicy covering both Delete and Retain.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Signed-off-by: Tiger Kaovilai <tkaovila@redhat.com>
(cherry picked from commit f4867d0489788ce0c7a63ffe08da4ad059db88b4)
Signed-off-by: Tiger Kaovilai <tkaovila@redhat.com>
2026-08-27 12:57:20 -04:00
..
2025-10-22 19:11:56 +08:00
2025-07-22 15:56:04 +08:00