GenericEventTypeMetrics (Apache Hadoop YARN Common 3.5.0 API)
Description: declaration: package: org.apache.hadoop.yarn.metrics, class: GenericEventTypeMetrics

Package org.apache.hadoop.yarn.metrics

# Class GenericEventTypeMetrics<T extends Enum<T>>

java.lang.Object
org.apache.hadoop.yarn.metrics.GenericEventTypeMetrics<T>

All Implemented Interfaces:
  `org.apache.hadoop.metrics2.MetricsSource`, `EventTypeMetrics<T>`

@Private @Metrics(context="yarn") public class GenericEventTypeMetrics<T extends Enum<T>> extends Object implements EventTypeMetrics<T>

- ## Nested Class Summary

  Nested Classes
  Modifier and Type
  Class
  Description
  `static class`
  `GenericEventTypeMetrics.EventTypeMetricsBuilder<T extends Enum<T>>`
  Builder class for GenericEventTypeMetrics.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `GenericEventTypeMetrics(org.apache.hadoop.metrics2.MetricsInfo info, org.apache.hadoop.metrics2.MetricsSystem ms, T[] enums, Class<T> enumClass)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `long`
  `get(T type)`
  `Class<T>`
  `getEnumClass()`
  `EnumMap<T,org.apache.hadoop.metrics2.lib.MutableGaugeLong>`
  `getEventCountMetrics()`
  `org.apache.hadoop.metrics2.MetricsInfo`
  `getInfo()`
  `void`
  `getMetrics(org.apache.hadoop.metrics2.MetricsCollector collector, boolean all)`
  `EnumMap<T,org.apache.hadoop.metrics2.lib.MutableGaugeLong>`
  `getProcessingTimeMetrics()`
  `org.apache.hadoop.metrics2.lib.MetricsRegistry`
  `getRegistry()`
  `long`
  `getTotalProcessingTime(T type)`
  `void`
  `increment(T type, long processingTimeUs)`
  `GenericEventTypeMetrics`
  `registerMetrics()`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### GenericEventTypeMetrics

    public GenericEventTypeMetrics(org.apache.hadoop.metrics2.MetricsInfo info, org.apache.hadoop.metrics2.MetricsSystem ms, T[] enums, Class<T> enumClass)

- ## Method Details

  - ### registerMetrics

    public GenericEventTypeMetrics registerMetrics()

  - ### increment

    public void increment(T type, long processingTimeUs)
    Specified by:
      `increment` in interface `EventTypeMetrics<T extends Enum<T>>`

  - ### get

    public long get(T type)
    Specified by:
      `get` in interface `EventTypeMetrics<T extends Enum<T>>`

  - ### getTotalProcessingTime

    public long getTotalProcessingTime(T type)

  - ### getEventCountMetrics

    public EnumMap<T,org.apache.hadoop.metrics2.lib.MutableGaugeLong> getEventCountMetrics()

  - ### getProcessingTimeMetrics

    public EnumMap<T,org.apache.hadoop.metrics2.lib.MutableGaugeLong> getProcessingTimeMetrics()

  - ### getRegistry

    public org.apache.hadoop.metrics2.lib.MetricsRegistry getRegistry()

  - ### getInfo

    public org.apache.hadoop.metrics2.MetricsInfo getInfo()

  - ### getMetrics

    public void getMetrics(org.apache.hadoop.metrics2.MetricsCollector collector, boolean all)
    Specified by:
      `getMetrics` in interface `org.apache.hadoop.metrics2.MetricsSource`

  - ### getEnumClass

    public Class<T> getEnumClass()