From 85994ed79de19caca6ee3f5c713db38a95f344c5 Mon Sep 17 00:00:00 2001 From: Shlomi Noach <2607934+shlomi-noach@users.noreply.github.com> Date: Thu, 11 Jul 2024 11:57:02 +0300 Subject: [PATCH] renamed getMySQLStoreMetric -> getScopedMetric Signed-off-by: Shlomi Noach <2607934+shlomi-noach@users.noreply.github.com> --- go/vt/vttablet/tabletserver/throttle/check.go | 2 +- go/vt/vttablet/tabletserver/throttle/throttler.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/go/vt/vttablet/tabletserver/throttle/check.go b/go/vt/vttablet/tabletserver/throttle/check.go index 069a1c275f5..e43c4cab043 100644 --- a/go/vt/vttablet/tabletserver/throttle/check.go +++ b/go/vt/vttablet/tabletserver/throttle/check.go @@ -163,7 +163,7 @@ func (check *ThrottlerCheck) Check(ctx context.Context, appName string, scope ba } metricResultFunc := func() (metricResult base.MetricResult, threshold float64) { - return check.throttler.getMySQLStoreMetric(ctx, metricScope, metricName) + return check.throttler.getScopedMetric(metricScope, metricName) } metricCheckResult := check.checkAppMetricResult(ctx, appName, metricResultFunc, flags) diff --git a/go/vt/vttablet/tabletserver/throttle/throttler.go b/go/vt/vttablet/tabletserver/throttle/throttler.go index 564651fff94..49a817c5952 100644 --- a/go/vt/vttablet/tabletserver/throttle/throttler.go +++ b/go/vt/vttablet/tabletserver/throttle/throttler.go @@ -1282,7 +1282,7 @@ func (throttler *Throttler) getAggregatedMetric(aggregatedName string) base.Metr return base.NoSuchMetric } -func (throttler *Throttler) getMySQLStoreMetric(ctx context.Context, scope base.Scope, metricName base.MetricName) (base.MetricResult, float64) { +func (throttler *Throttler) getScopedMetric(scope base.Scope, metricName base.MetricName) (base.MetricResult, float64) { thresholdVal, found := throttler.metricThresholds.Get(metricName.String()) if !found { return base.NoSuchMetric, 0