Package org.apache.hadoop.hbase.metrics
Interface BaseSource
- All Known Subinterfaces:
ExceptionTrackingSource
,MetricsAssignmentManagerSource
,MetricsBalancerSource
,MetricsHBaseServerSource
,MetricsHeapMemoryManagerSource
,MetricsIOSource
,MetricsMasterFileSystemSource
,MetricsMasterProcSource
,MetricsMasterQuotaSource
,MetricsMasterSource
,MetricsRegionAggregateSource
,MetricsRegionServerQuotaSource
,MetricsRegionServerSource
,MetricsReplicationGlobalSourceSource
,MetricsReplicationSource
,MetricsReplicationSourceSource
,MetricsReplicationTableSource
,MetricsRESTSource
,MetricsSnapshotSource
,MetricsStochasticBalancerSource
,MetricsTableAggregateSource
,MetricsThriftServerSource
,MetricsUserAggregateSource
,MetricsWALEventTrackerSource
,MetricsWALSource
,MetricsZooKeeperSource
- All Known Implementing Classes:
BaseSourceImpl
,ExceptionTrackingSourceImpl
,MetricsAssignmentManagerSourceImpl
,MetricsBalancerSourceImpl
,MetricsHBaseServerSourceImpl
,MetricsHeapMemoryManagerSourceImpl
,MetricsIOSourceImpl
,MetricsMasterFilesystemSourceImpl
,MetricsMasterProcSourceImpl
,MetricsMasterQuotaSourceImpl
,MetricsMasterSourceImpl
,MetricsRegionAggregateSourceImpl
,MetricsRegionServerQuotaSourceImpl
,MetricsRegionServerSourceImpl
,MetricsReplicationGlobalSourceSourceImpl
,MetricsReplicationSourceImpl
,MetricsReplicationSourceSourceImpl
,MetricsReplicationTableSourceImpl
,MetricsRESTSourceImpl
,MetricsSnapshotSourceImpl
,MetricsSource
,MetricsStochasticBalancerSourceImpl
,MetricsTableAggregateSourceImpl
,MetricsThriftServerSourceImpl
,MetricsUserAggregateSourceImpl
,MetricsWALEventTrackerSourceImpl
,MetricsWALSourceImpl
,MetricsZooKeeperSourceImpl
BaseSource for dynamic metrics to announce to Metrics2. In hbase-hadoop{1|2}-compat there is an
implementation of this interface.
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Subtract some amount from a gauge.default MetricRegistryInfo
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.void
incCounters
(String counterName, long delta) Add some amount to a counter.void
Add some amount to a gauge.void
init()
Clear out the metrics and re-prepare the source.void
removeMetric
(String key) Remove a metric and no longer announce it.void
Set a gauge to a specific value.void
updateHistogram
(String name, long value) Add some value to a histogram.
-
Field Details
-
HBASE_METRICS_SYSTEM_NAME
- See Also:
-
-
Method Details
-
init
void init()Clear out the metrics and re-prepare the source. -
setGauge
Set a gauge to a specific value.- Parameters:
gaugeName
- the name of the gaugevalue
- the value
-
incGauge
Add some amount to a gauge.- Parameters:
gaugeName
- the name of the gaugedelta
- the amount to change the gauge by.
-
decGauge
Subtract some amount from a gauge.- Parameters:
gaugeName
- the name of the gaugedelta
- the amount to change the gauge by.
-
removeMetric
Remove a metric and no longer announce it.- Parameters:
key
- Name of the gauge to remove.
-
incCounters
Add some amount to a counter.- Parameters:
counterName
- the name of the counterdelta
- the amount to change the counter by.
-
updateHistogram
Add some value to a histogram.- Parameters:
name
- the name of the histogramvalue
- the value to add to the histogram
-
getMetricsContext
Get the metrics context. For hadoop metrics2 system this is usually an all lowercased string. eg. regionserver, master, thriftserver- Returns:
- The string context used to register this source to hadoop's metrics2 system.
-
getMetricsDescription
Get the description of what this source exposes. -
getMetricsJmxContext
Get 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 -
getMetricsName
Get the name of the metrics that are being exported by this source. Eg. IPC, GC, WAL -
getMetricRegistryInfo
-