Interface CountersAndGauges
- All Superinterfaces:
org.apache.hadoop.fs.statistics.DurationTrackerFactory
- All Known Subinterfaces:
S3AStatisticsContext
- All Known Implementing Classes:
BondedS3AStatisticsContext,EmptyS3AStatisticsContext,S3AInstrumentation
public interface CountersAndGauges
extends org.apache.hadoop.fs.statistics.DurationTrackerFactory
This is the foundational API for collecting S3A statistics.
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddValueToQuantiles(Statistic op, long value) Add a value to a quantiles statistic.voiddecrementGauge(Statistic op, long count) Decrement a specific gauge.voidincrementCounter(Statistic op, long count) Increment a specific counter.voidincrementGauge(Statistic op, long count) Increment a specific gauge.voidrecordDuration(Statistic op, boolean success, Duration duration) Record a duration.Methods inherited from interface org.apache.hadoop.fs.statistics.DurationTrackerFactory
trackDuration, trackDuration
-
Method Details
-
incrementCounter
Increment a specific counter. No-op if not defined.- Parameters:
op- operationcount- increment value
-
incrementGauge
Increment a specific gauge. No-op if not defined.- Parameters:
op- operationcount- increment value- Throws:
ClassCastException- if the metric is of the wrong type
-
decrementGauge
Decrement a specific gauge. No-op if not defined.- Parameters:
op- operationcount- increment value- Throws:
ClassCastException- if the metric is of the wrong type
-
addValueToQuantiles
Add a value to a quantiles statistic. No-op if the quantile isn't found.- Parameters:
op- operation to look up.value- value to add.- Throws:
ClassCastException- if the metric is not a Quantiles.
-
recordDuration
Record a duration.- Parameters:
op- operationsuccess- was the operation a success?duration- how long did it take
-