Class MetricsUtil


  • public final class MetricsUtil
    extends Object
    • Method Detail

      • startTimer

        public static com.codahale.metrics.Timer.Context startTimer​(com.codahale.metrics.Timer timer)
        Starts the Metric Timer.

        If the given timer was null, it will silently return null.

        Parameters:
        timer - timer to start
        Returns:
        timing context, if timer was not null
      • stopTimer

        public static void stopTimer​(com.codahale.metrics.Timer.Context context)
        Stops the Metric Timer context.

        If the given context was null, it will silently be ignored.

        Parameters:
        context - timing context to stop, if not null.