Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KO-341: Added event flow for BackupService, Backup and Restore controllers #324

Merged
merged 4 commits into from
Jan 6, 2025

Conversation

jwalantmodi05
Copy link
Contributor

No description provided.

Copy link
Contributor

@tanmayja tanmayja left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should enhance event tracking by incorporating additional events, especially for the successful (happy path) scenarios. Currently, only failure and deletion events are being logged, leaving gaps in visibility for standard operations.

internal/controller/backup-service/reconciler.go Outdated Show resolved Hide resolved
internal/controller/backup/reconciler.go Outdated Show resolved Hide resolved
internal/controller/restore/reconciler.go Outdated Show resolved Hide resolved
internal/controller/restore/reconciler.go Outdated Show resolved Hide resolved
@@ -308,8 +330,10 @@ func (r *SingleBackupReconciler) scheduleOnDemandBackup() error {

r.Log.Info("Scheduled on-demand backup", "ID", r.aeroBackup.Spec.OnDemandBackups[0].ID,
"routine", r.aeroBackup.Spec.OnDemandBackups[0].RoutineName)
r.Recorder.Eventf(r.aeroBackup, corev1.EventTypeNormal, "BackupScheduled",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
r.Recorder.Eventf(r.aeroBackup, corev1.EventTypeNormal, "BackupScheduled",
r.Recorder.Eventf(r.aeroBackup, corev1.EventTypeNormal, "OnDemandBackupScheduled",

Comment on lines +448 to +449
r.Recorder.Eventf(r.aeroBackup, corev1.EventTypeNormal, "BackupReconciled",
"Reconciled scheduled backup %s/%s", r.aeroBackup.Namespace, r.aeroBackup.Name)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
r.Recorder.Eventf(r.aeroBackup, corev1.EventTypeNormal, "BackupReconciled",
"Reconciled scheduled backup %s/%s", r.aeroBackup.Namespace, r.aeroBackup.Name)
r.Recorder.Eventf(r.aeroBackup, corev1.EventTypeNormal, "BackupScheduled",
"Scheduled backup %s/%s", r.aeroBackup.Namespace, r.aeroBackup.Name)

@sud82 sud82 merged commit 50692f9 into master Jan 6, 2025
8 of 9 checks passed
@sud82 sud82 deleted the add-event-flow branch January 6, 2025 05:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants