Class MetricsRegionAggregateSourceImpl
java.lang.Object
org.apache.hadoop.hbase.metrics.BaseSourceImpl
org.apache.hadoop.hbase.regionserver.MetricsRegionAggregateSourceImpl
- All Implemented Interfaces:
- BaseSource,- MetricsRegionAggregateSource,- org.apache.hadoop.metrics2.MetricsSource
@Private
public class MetricsRegionAggregateSourceImpl
extends BaseSourceImpl
implements MetricsRegionAggregateSource
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprivate final MetricsExecutorImplprivate static final org.slf4j.Loggerprivate final Set<MetricsRegionSource>Fields inherited from class org.apache.hadoop.hbase.metrics.BaseSourceImplmetricsAdapter, metricsContext, metricsDescription, metricsJmxContext, metricsName, metricsRegistry, registryFields inherited from interface org.apache.hadoop.hbase.metrics.BaseSourceHBASE_METRICS_SYSTEM_NAMEFields inherited from interface org.apache.hadoop.hbase.regionserver.MetricsRegionAggregateSourceMETRICS_CONTEXT, METRICS_DESCRIPTION, METRICS_JMX_CONTEXT, METRICS_NAME
- 
Constructor SummaryConstructorsConstructorDescriptionMetricsRegionAggregateSourceImpl(String metricsName, String metricsDescription, String metricsContext, String metricsJmxContext) 
- 
Method SummaryModifier and TypeMethodDescriptionprivate voidvoidderegister(MetricsRegionSource toRemove) Remove a region's source.voidgetMetrics(org.apache.hadoop.metrics2.MetricsCollector collector, boolean all) Yes this is a get function that doesn't return anything.voidregister(MetricsRegionSource source) Register a MetricsRegionSource as being open.Methods inherited from class org.apache.hadoop.hbase.metrics.BaseSourceImpldecGauge, getMetricsContext, getMetricsDescription, getMetricsJmxContext, getMetricsName, getMetricsRegistry, incCounters, incGauge, init, removeMetric, setGauge, updateHistogramMethods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.hadoop.hbase.metrics.BaseSourcedecGauge, getMetricRegistryInfo, getMetricsContext, getMetricsDescription, getMetricsJmxContext, getMetricsName, incCounters, incGauge, init, removeMetric, setGauge, updateHistogram
- 
Field Details- 
LOG
- 
executor
- 
regionSources
 
- 
- 
Constructor Details- 
MetricsRegionAggregateSourceImplpublic MetricsRegionAggregateSourceImpl()
- 
MetricsRegionAggregateSourceImplpublic MetricsRegionAggregateSourceImpl(String metricsName, String metricsDescription, String metricsContext, String metricsJmxContext) 
 
- 
- 
Method Details- 
registerDescription copied from interface:MetricsRegionAggregateSourceRegister a MetricsRegionSource as being open.- Specified by:
- registerin interface- MetricsRegionAggregateSource
- Parameters:
- source- the source for the region being opened.
 
- 
deregisterDescription copied from interface:MetricsRegionAggregateSourceRemove a region's source. This is called when a region is closed.- Specified by:
- deregisterin interface- MetricsRegionAggregateSource
- Parameters:
- toRemove- The region to remove.
 
- 
clearCache
- 
getMetricsYes this is a get function that doesn't return anything. Thanks Hadoop for breaking all expectations of java programmers. Instead of returning anything Hadoop metrics expects getMetrics to push the metrics into the collector.- Specified by:
- getMetricsin interface- org.apache.hadoop.metrics2.MetricsSource
- Overrides:
- getMetricsin class- BaseSourceImpl
- Parameters:
- collector- the collector
- all- get all the metrics regardless of when they last changed.
 
 
-