DurationTrackerFactory, IOStatisticsStore, IOStatistics, IOStatisticsAggregator, IOStatisticsSetterspublic class ForwardingIOStatisticsStore extends java.lang.Object implements IOStatisticsStore
MAX_UNSET_VALUE, MIN_UNSET_VALUE| Constructor | Description |
|---|---|
ForwardingIOStatisticsStore(IOStatisticsStore innerStatistics) |
| Modifier and Type | Method | Description |
|---|---|---|
void |
addMaximumSample(java.lang.String key,
long value) |
Add a maximum sample: if greater than the current value,
updates the value.
|
void |
addMeanStatisticSample(java.lang.String key,
long value) |
Add a sample to the mean statistics.
|
void |
addMinimumSample(java.lang.String key,
long value) |
Add a minimum sample: if less than the current value,
updates the value.
|
void |
addTimedOperation(java.lang.String prefix,
long durationMillis) |
Add a duration to the min/mean/max statistics, using the
given prefix and adding a suffix for each specific value.
|
void |
addTimedOperation(java.lang.String prefix,
java.time.Duration duration) |
Add a duration to the min/mean/max statistics, using the
given prefix and adding a suffix for each specific value.;
increment tha counter whose name == prefix.
|
boolean |
aggregate(IOStatistics statistics) |
Aggregate the supplied statistics into the current
set.
|
java.util.Map<java.lang.String,java.lang.Long> |
counters() |
Map of counters.
|
java.util.Map<java.lang.String,java.lang.Long> |
gauges() |
Map of gauges.
|
java.util.concurrent.atomic.AtomicLong |
getCounterReference(java.lang.String key) |
Get a reference to the atomic instance providing the
value for a specific counter.
|
java.util.concurrent.atomic.AtomicLong |
getGaugeReference(java.lang.String key) |
Get a reference to the atomic instance providing the
value for a specific gauge.
|
protected IOStatisticsStore |
getInnerStatistics() |
|
java.util.concurrent.atomic.AtomicLong |
getMaximumReference(java.lang.String key) |
Get a reference to the atomic instance providing the
value for a specific maximum.
|
MeanStatistic |
getMeanStatistic(java.lang.String key) |
Get a reference to the atomic instance providing the
value for a specific meanStatistic.
|
java.util.concurrent.atomic.AtomicLong |
getMinimumReference(java.lang.String key) |
Get a reference to the atomic instance providing the
value for a specific minimum.
|
long |
incrementCounter(java.lang.String key,
long value) |
Increment a counter.
|
long |
incrementGauge(java.lang.String key,
long value) |
Increment a gauge.
|
long |
incrementMaximum(java.lang.String key,
long value) |
Increment a maximum.
|
long |
incrementMinimum(java.lang.String key,
long value) |
Increment a minimum.
|
java.util.Map<java.lang.String,java.lang.Long> |
maximums() |
Map of maximums.
|
java.util.Map<java.lang.String,MeanStatistic> |
meanStatistics() |
Map of meanStatistics.
|
java.util.Map<java.lang.String,java.lang.Long> |
minimums() |
Map of minimums.
|
void |
reset() |
Reset all statistics.
|
void |
setCounter(java.lang.String key,
long value) |
Set a counter.
|
void |
setGauge(java.lang.String key,
long value) |
Set a gauge.
|
void |
setMaximum(java.lang.String key,
long value) |
Set a maximum.
|
void |
setMeanStatistic(java.lang.String key,
MeanStatistic value) |
Set a mean statistic to a given value.
|
void |
setMinimum(java.lang.String key,
long value) |
Set a minimum.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waittrackDuration, trackDurationaddSample, incrementCounterpublic ForwardingIOStatisticsStore(IOStatisticsStore innerStatistics)
protected IOStatisticsStore getInnerStatistics()
public java.util.Map<java.lang.String,java.lang.Long> counters()
IOStatisticscounters in interface IOStatisticspublic java.util.Map<java.lang.String,java.lang.Long> gauges()
IOStatisticsgauges in interface IOStatisticspublic java.util.Map<java.lang.String,java.lang.Long> minimums()
IOStatisticsminimums in interface IOStatisticspublic java.util.Map<java.lang.String,java.lang.Long> maximums()
IOStatisticsmaximums in interface IOStatisticspublic java.util.Map<java.lang.String,MeanStatistic> meanStatistics()
IOStatisticsmeanStatistics in interface IOStatisticspublic boolean aggregate(@Nullable
IOStatistics statistics)
IOStatisticsAggregatoraggregate in interface IOStatisticsAggregatorstatistics - statistics; may be nullpublic long incrementCounter(java.lang.String key,
long value)
IOStatisticsStoreincrementCounter in interface IOStatisticsStorekey - statistics keyvalue - value to incrementpublic void setCounter(java.lang.String key,
long value)
IOStatisticsSetterssetCounter in interface IOStatisticsSetterskey - statistics keyvalue - value to setpublic void setGauge(java.lang.String key,
long value)
IOStatisticsSetterssetGauge in interface IOStatisticsSetterskey - statistics keyvalue - value to setpublic long incrementGauge(java.lang.String key,
long value)
IOStatisticsStoreNo-op if the gauge is unknown.
incrementGauge in interface IOStatisticsStorekey - statistics keyvalue - value to incrementpublic void setMaximum(java.lang.String key,
long value)
IOStatisticsSetterssetMaximum in interface IOStatisticsSetterskey - statistics keyvalue - value to setpublic long incrementMaximum(java.lang.String key,
long value)
IOStatisticsStoreNo-op if the maximum is unknown.
incrementMaximum in interface IOStatisticsStorekey - statistics keyvalue - value to incrementpublic void setMinimum(java.lang.String key,
long value)
IOStatisticsSetterssetMinimum in interface IOStatisticsSetterskey - statistics keyvalue - value to setpublic long incrementMinimum(java.lang.String key,
long value)
IOStatisticsStoreNo-op if the minimum is unknown.
incrementMinimum in interface IOStatisticsStorekey - statistics keyvalue - value to incrementpublic void addMinimumSample(java.lang.String key,
long value)
IOStatisticsStoreNo-op if the minimum is unknown.
addMinimumSample in interface IOStatisticsStorekey - statistics keyvalue - sample valuepublic void addMaximumSample(java.lang.String key,
long value)
IOStatisticsStoreNo-op if the key is unknown.
addMaximumSample in interface IOStatisticsStorekey - statistics keyvalue - sample valuepublic void setMeanStatistic(java.lang.String key,
MeanStatistic value)
IOStatisticsSetterssetMeanStatistic in interface IOStatisticsSetterskey - statistic keyvalue - new value.public void addMeanStatisticSample(java.lang.String key,
long value)
IOStatisticsStoreNo-op if the key is unknown.
addMeanStatisticSample in interface IOStatisticsStorekey - keyvalue - sample value.public void reset()
IOStatisticsStorereset in interface IOStatisticsStorepublic java.util.concurrent.atomic.AtomicLong getCounterReference(java.lang.String key)
IOStatisticsStoregetCounterReference in interface IOStatisticsStorekey - statistic namepublic java.util.concurrent.atomic.AtomicLong getMaximumReference(java.lang.String key)
IOStatisticsStoregetMaximumReference in interface IOStatisticsStorekey - statistic namepublic java.util.concurrent.atomic.AtomicLong getMinimumReference(java.lang.String key)
IOStatisticsStoregetMinimumReference in interface IOStatisticsStorekey - statistic namepublic java.util.concurrent.atomic.AtomicLong getGaugeReference(java.lang.String key)
IOStatisticsStoregetGaugeReference in interface IOStatisticsStorekey - statistic namepublic MeanStatistic getMeanStatistic(java.lang.String key)
IOStatisticsStoregetMeanStatistic in interface IOStatisticsStorekey - statistic namepublic void addTimedOperation(java.lang.String prefix,
long durationMillis)
IOStatisticsStoreaddTimedOperation in interface IOStatisticsStoreprefix - statistic prefixdurationMillis - duration in milliseconds.public void addTimedOperation(java.lang.String prefix,
java.time.Duration duration)
IOStatisticsStoreaddTimedOperation in interface IOStatisticsStoreprefix - statistic prefixduration - durationCopyright © 2008–2025 Apache Software Foundation. All rights reserved.