From f43eccab6443de22ade95a6c29b33d65ac994c9b Mon Sep 17 00:00:00 2001 From: "Wang, Fei" Date: Thu, 26 Dec 2024 14:41:59 -0800 Subject: [PATCH] prevent conflicts --- .../scala/org/apache/kyuubi/metrics/MetricsSystem.scala | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/kyuubi-metrics/src/main/scala/org/apache/kyuubi/metrics/MetricsSystem.scala b/kyuubi-metrics/src/main/scala/org/apache/kyuubi/metrics/MetricsSystem.scala index ee945da2618..998942362ff 100644 --- a/kyuubi-metrics/src/main/scala/org/apache/kyuubi/metrics/MetricsSystem.scala +++ b/kyuubi-metrics/src/main/scala/org/apache/kyuubi/metrics/MetricsSystem.scala @@ -123,11 +123,11 @@ object MetricsSystem { maybeSystem.map(_.registry.meter(name).getCount) } - def getGauge(name: String): Option[Gauge[_]] = { - maybeSystem.map(_.registry.gauge(name)) - } - def histogramSnapshot(name: String): Option[Snapshot] = { maybeSystem.map(_.registry.histogram(name).getSnapshot) } + + def getGauge[T](name: String): Option[Gauge[T]] = { + maybeSystem.map(_.registry.gauge(name)) + } }