From a768340bcdc8175f8593c70d53f93bff04ecf249 Mon Sep 17 00:00:00 2001 From: Zbynek Roubalik <726523+zroubalik@users.noreply.github.com> Date: Tue, 25 Aug 2020 22:22:24 +0200 Subject: [PATCH] [v2] don't inspect other scalers if one is active (#1036) Signed-off-by: Zbynek Roubalik --- pkg/scaling/scale_handler.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/scaling/scale_handler.go b/pkg/scaling/scale_handler.go index 7127422852d..cccd6267893 100644 --- a/pkg/scaling/scale_handler.go +++ b/pkg/scaling/scale_handler.go @@ -208,7 +208,8 @@ func (h *scaleHandler) checkScaledObjectScalers(ctx context.Context, scalers []s continue } else if isTriggerActive { isActive = true - h.logger.V(1).Info("Scaler for scaledObject is active", "Scaler", scaler) + h.logger.V(1).Info("Scaler for scaledObject is active", "Metrics Name", scaler.GetMetricSpecForScaling()[0].External.Metric.Name) + break } } return isActive