Interface Meter

  • All Superinterfaces:
    AutoCloseable, org.opendaylight.yangtools.concepts.Registration

    public interface Meter
    extends org.opendaylight.yangtools.concepts.Registration
    Meter metric, which measures throughput.

    Note that this with mark() measures the rate at which a set of events occur; whereas Counter is for things which will increase() - and can also decrease().

    • Method Summary

      All Methods Instance Methods Abstract Methods Default Methods 
      Modifier and Type Method Description
      long get()
      Gets the total number of events.
      default void mark()
      Mark the occurrence of an event.
      void mark​(long howMany)
      Mark the occurrence of a given number of events.
      • Methods inherited from interface org.opendaylight.yangtools.concepts.Registration

        close
    • Method Detail

      • mark

        default void mark()
        Mark the occurrence of an event.
      • mark

        void mark​(long howMany)
        Mark the occurrence of a given number of events.
      • get

        long get()
        Gets the total number of events. Beware that this could have overflown. This is typically used in unit tests of metrics, more than to expose the metrics in production (because exposing metrics is really the role of the infrautils metrics implementation of this API).