Skip to content

Commit a086560

Browse files
priyansh17blackpiglet
authored andcommitted
Refactor error handling in backup deletion
Signed-off-by: Priyansh Choudhary <im1706@gmail.com>
1 parent bb591af commit a086560

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

pkg/controller/backup_deletion_controller.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -271,14 +271,12 @@ func (r *backupDeletionReconciler) Reconcile(ctx context.Context, req ctrl.Reque
271271
// Best-effort fallback for pre-v1.15 backups where VS/VSC may still exist in cluster
272272
log.Info("Cleaning up CSI volumesnapshots")
273273
r.deleteCSIVolumeSnapshotsIfAny(ctx, backup, log)
274-
log.Info("Cleaning up CSI volumesnapshotcontents")
275-
r.deleteCSIVolumeSnapshotContentsIfAny(ctx, backup, log)
276274
// If the tarball simply does not exist (HTTP 404 / not found), the download
277275
// failure is permanent and not retryable, so we let deletion proceed.
278276
// For transient errors (throttling, auth failures, network issues), record
279277
// the error to fail the deletion so it can be retried later.
280278
if !isTarballNotFoundError(err) {
281-
errs = append(errs, errors.Wrapf(err, "error downloading backup tarball, CSI snapshot cleanup was skipped").Error())
279+
errs = append(errs, errors.Wrapf(err, "error downloading backup tarball").Error())
282280
}
283281
} else {
284282
defer closeAndRemoveFile(backupFile, r.logger)

0 commit comments

Comments
 (0)