From 225aacc6a505bc65a65a7c588d4f987345c5d86d Mon Sep 17 00:00:00 2001 From: Rizwana777 Date: Fri, 24 Jan 2025 15:45:47 +0530 Subject: [PATCH] display the warning instead of returning an error Signed-off-by: Rizwana777 --- controllers/argocd/argocd_controller.go | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/controllers/argocd/argocd_controller.go b/controllers/argocd/argocd_controller.go index da401d410..1243d38b0 100644 --- a/controllers/argocd/argocd_controller.go +++ b/controllers/argocd/argocd_controller.go @@ -130,11 +130,9 @@ func (r *ReconcileArgoCD) internalReconcile(ctx context.Context, request ctrl.Re return reconcile.Result{}, argocd, err } - // If the number of notification replicas is greater than 1, return an error + // If the number of notification replicas is greater than 1, display a warning. if argocd.Spec.Notifications.Replicas != nil && *argocd.Spec.Notifications.Replicas > 1 { - message := "Argo CD Notification controller does not support multiple replicas. Notification replicas cannot be greater than 1." - reqLogger.Info(message) - return reconcile.Result{}, argocd, fmt.Errorf("%s", message) + reqLogger.Info("WARNING: Argo CD Notification controller does not support multiple replicas. Notification replicas cannot be greater than 1.") } // Fetch labelSelector from r.LabelSelector (command-line option)