Skip to content

Commit ea7c496

Browse files
authored
fix(backup): use correct pod name in event when pod is not found (#9552)
In isValidBackupRunning, when the elected backup pod is not found, the event message was incorrectly referencing pod.Name which is empty since the Get() call returned NotFound. Changed to use the actual pod name from backup.Status.InstanceID.PodName which contains the name of the pod that couldn't be found. Signed-off-by: Armando Ruocco <[email protected]>
1 parent 35664dd commit ea7c496

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎internal/controller/backup_controller.go‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -451,7 +451,7 @@ func (r *BackupReconciler) isValidBackupRunning(
451451
"ReStarting",
452452
"Could not find the elected backup pod. Restarting backup for cluster %v on instance %v",
453453
cluster.Name,
454-
pod.Name,
454+
backup.Status.InstanceID.PodName,
455455
)
456456
return false, nil
457457
}

0 commit comments

Comments
 (0)