From b7ddec65a0dc44a13f1aa6a14099ce0724a85655 Mon Sep 17 00:00:00 2001 From: Rewant Soni Date: Tue, 3 Dec 2024 21:44:31 +0530 Subject: [PATCH] controllers: fix predicate to trigger reconcile for mmode controller add an predicate.Or trigger reconcile of mmode controller when the storageClient's status is updated Signed-off-by: Rewant Soni --- internal/controller/maintenancemode_controller.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/internal/controller/maintenancemode_controller.go b/internal/controller/maintenancemode_controller.go index 8dc14997..58f83125 100644 --- a/internal/controller/maintenancemode_controller.go +++ b/internal/controller/maintenancemode_controller.go @@ -64,8 +64,10 @@ func (r *MaintenanceModeReconciler) SetupWithManager(mgr ctrl.Manager) error { &v1alpha1.StorageClient{}, &handler.EnqueueRequestForObject{}, builder.WithPredicates( - generationChangePredicate, - maintenanceModeChangedPredicate, + predicate.Or( + generationChangePredicate, + maintenanceModeChangedPredicate, + ), ), ). Complete(r)