From 4c96c83d39321b2d043bb1de28cd0a59d9ea06f5 Mon Sep 17 00:00:00 2001 From: akats7 Date: Mon, 31 Jul 2023 12:05:56 -0400 Subject: [PATCH] Updated function name --- .../io/opentelemetry/contrib/jmxmetrics/MBeanHelper.groovy | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/jmx-metrics/src/main/groovy/io/opentelemetry/contrib/jmxmetrics/MBeanHelper.groovy b/jmx-metrics/src/main/groovy/io/opentelemetry/contrib/jmxmetrics/MBeanHelper.groovy index e8eec8542..9cabdecf2 100644 --- a/jmx-metrics/src/main/groovy/io/opentelemetry/contrib/jmxmetrics/MBeanHelper.groovy +++ b/jmx-metrics/src/main/groovy/io/opentelemetry/contrib/jmxmetrics/MBeanHelper.groovy @@ -105,7 +105,7 @@ class MBeanHelper { def ofInterest = isSingle ? [mbeans[0]]: mbeans return ofInterest.collect { - getBeanAttributeTransform(it, attribute) + getBeanAttributeWithTransform(it, attribute) } } @@ -117,11 +117,11 @@ class MBeanHelper { def ofInterest = isSingle ? [mbeans[0]]: mbeans return [ofInterest, attributes].combinations().collect { pair -> def (bean, attribute) = pair - new Tuple3(bean, attribute, getBeanAttributeTransform(bean, attribute)) + new Tuple3(bean, attribute, getBeanAttributeWithTransform(bean, attribute)) } } - Object getBeanAttributeTransform(GroovyMBean bean, String attribute){ + Object getBeanAttributeWithTransform(GroovyMBean bean, String attribute){ def transformationClosure = attributeTransformation.get(attribute); return transformationClosure != null ? transformationClosure(bean) : getBeanAttribute(bean, attribute) }