Package org.apache.hadoop.hbase.io
Class MetricsIO.NoOpMetricsIOSource
java.lang.Object
org.apache.hadoop.hbase.io.MetricsIO.NoOpMetricsIOSource
- All Implemented Interfaces:
MetricsIOSource,BaseSource
- Enclosing class:
- MetricsIO
A
MetricsIOSource that discards all updates. Used while IO metrics are disabled, or
when the real metrics source could not be created.-
Field Summary
Fields inherited from interface org.apache.hadoop.hbase.metrics.BaseSource
HBASE_METRICS_SYSTEM_NAMEFields inherited from interface org.apache.hadoop.hbase.io.MetricsIOSource
CHECKSUM_FAILURES_DESC, CHECKSUM_FAILURES_KEY, FS_PREAD_TIME_HISTO_DESC, FS_PREAD_TIME_HISTO_KEY, FS_READ_TIME_HISTO_DESC, FS_READ_TIME_HISTO_KEY, FS_WRITE_HISTO_KEY, FS_WRITE_TIME_HISTO_DESC, METRICS_CONTEXT, METRICS_DESCRIPTION, METRICS_JMX_CONTEXT, METRICS_NAME, SLOW_FS_READS_DESC, SLOW_FS_READS_KEY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidSubtract some amount from a gauge.Get the metrics context.Get the description of what this source exposes.Get the name of the context in JMX that this source will be exposed through.Get the name of the metrics that are being exported by this source.voidincCounters(String counterName, long delta) Add some amount to a counter.voidAdd some amount to a gauge.voidvoidinit()Clear out the metrics and re-prepare the source.voidremoveMetric(String key) Remove a metric and no longer announce it.voidSet a gauge to a specific value.voidupdateFsPReadTime(long t) Update the fs positional read time histogramvoidupdateFsReadTime(long t) Update the fs sequential read time histogramvoidupdateFsWriteTime(long t) Update the fs write time histogramvoidupdateHistogram(String name, long value) Add some value to a histogram.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.hadoop.hbase.metrics.BaseSource
getMetricRegistryInfo
-
Constructor Details
-
NoOpMetricsIOSource
-
-
Method Details
-
updateFsReadTime
Description copied from interface:MetricsIOSourceUpdate the fs sequential read time histogram- Specified by:
updateFsReadTimein interfaceMetricsIOSource- Parameters:
t- time it took, in milliseconds
-
updateFsPReadTime
Description copied from interface:MetricsIOSourceUpdate the fs positional read time histogram- Specified by:
updateFsPReadTimein interfaceMetricsIOSource- Parameters:
t- time it took, in milliseconds
-
updateFsWriteTime
Description copied from interface:MetricsIOSourceUpdate the fs write time histogram- Specified by:
updateFsWriteTimein interfaceMetricsIOSource- Parameters:
t- time it took, in milliseconds
-
incrSlowFsRead
- Specified by:
incrSlowFsReadin interfaceMetricsIOSource
-
init
Description copied from interface:BaseSourceClear out the metrics and re-prepare the source.- Specified by:
initin interfaceBaseSource
-
setGauge
Description copied from interface:BaseSourceSet a gauge to a specific value.- Specified by:
setGaugein interfaceBaseSource- Parameters:
gaugeName- the name of the gaugevalue- the value
-
incGauge
Description copied from interface:BaseSourceAdd some amount to a gauge.- Specified by:
incGaugein interfaceBaseSource- Parameters:
gaugeName- the name of the gaugedelta- the amount to change the gauge by.
-
decGauge
Description copied from interface:BaseSourceSubtract some amount from a gauge.- Specified by:
decGaugein interfaceBaseSource- Parameters:
gaugeName- the name of the gaugedelta- the amount to change the gauge by.
-
removeMetric
Description copied from interface:BaseSourceRemove a metric and no longer announce it.- Specified by:
removeMetricin interfaceBaseSource- Parameters:
key- Name of the gauge to remove.
-
incCounters
Description copied from interface:BaseSourceAdd some amount to a counter.- Specified by:
incCountersin interfaceBaseSource- Parameters:
counterName- the name of the counterdelta- the amount to change the counter by.
-
updateHistogram
Description copied from interface:BaseSourceAdd some value to a histogram.- Specified by:
updateHistogramin interfaceBaseSource- Parameters:
name- the name of the histogramvalue- the value to add to the histogram
-
getMetricsContext
Description copied from interface:BaseSourceGet the metrics context. For hadoop metrics2 system this is usually an all lowercased string. eg. regionserver, master, thriftserver- Specified by:
getMetricsContextin interfaceBaseSource- Returns:
- The string context used to register this source to hadoop's metrics2 system.
-
getMetricsDescription
Description copied from interface:BaseSourceGet the description of what this source exposes.- Specified by:
getMetricsDescriptionin interfaceBaseSource
-
getMetricsJmxContext
Description copied from interface:BaseSourceGet the name of the context in JMX that this source will be exposed through. This is in ObjectName format. With the default context being Hadoop -> HBase- Specified by:
getMetricsJmxContextin interfaceBaseSource
-
getMetricsName
Description copied from interface:BaseSourceGet the name of the metrics that are being exported by this source. Eg. IPC, GC, WAL- Specified by:
getMetricsNamein interfaceBaseSource
-