Class MetricUtil


  • public final class MetricUtil
    extends Object
    Class MetricUtil.
    • Method Detail

      • lookupAnnotation

        @Deprecated
        public static <E extends Member & AnnotatedElement,​A extends AnnotationMetricUtil.LookupResult<A> lookupAnnotation​(E element,
                                                                                                                                   Class<? extends Annotation> annotClass,
                                                                                                                                   Class<?> clazz)
        Deprecated.
        This method is made public to migrate from metrics1 to metrics2 for gRPC, this should be refactored
        DO NOT USE THIS METHOD please.
        Type Parameters:
        E - element type
        A - annotation type
        Parameters:
        element - element
        annotClass - annotation class
        clazz - class
        Returns:
        lookup result
      • getMetricName

        public static <E extends Member & AnnotatedElementString getMetricName​(E element,
                                                                                 Class<?> clazz,
                                                                                 MetricUtil.MatchingType matchingType,
                                                                                 String explicitName,
                                                                                 boolean absolute)
        This method is intended only for other Helidon components.
        Type Parameters:
        E - type of element
        Parameters:
        element - such as method
        clazz - class
        matchingType - type to match
        explicitName - name
        absolute - if absolute
        Returns:
        name of the metric