Class HistogramImpl
java.lang.Object
org.apache.hadoop.hbase.metrics.impl.HistogramImpl
Custom histogram implementation based on FastLongHistogram. Dropwizard-based histograms are slow
compared to this implementation, so we are using our implementation here. See HBASE-15222.
-
Field Summary
-
Constructor Summary
ModifierConstructorDescriptionHistogramImpl
(int numBins, long min, long maxExpected) HistogramImpl
(long maxExpected) protected
HistogramImpl
(CounterImpl counter, FastLongHistogram histogram) -
Method Summary
Modifier and TypeMethodDescriptionlong
getCount()
Return the total number of values added to the histogram.long
getMax()
long
getMin()
long[]
getQuantiles
(double[] quantiles) snapshot()
Snapshot the current values in the Histogramvoid
update
(int value) Adds a new value to the distribution.void
update
(long value) Adds a new value to the distribution.
-
Field Details
-
histogram
-
counter
-
-
Constructor Details
-
HistogramImpl
public HistogramImpl() -
HistogramImpl
-
HistogramImpl
-
HistogramImpl
-
-
Method Details
-
update
Description copied from interface:Histogram
Adds a new value to the distribution. -
update
Description copied from interface:Histogram
Adds a new value to the distribution. -
getCount
Description copied from interface:Histogram
Return the total number of values added to the histogram. -
getMax
-
getMin
-
snapshot
Description copied from interface:Histogram
Snapshot the current values in the Histogram -
getQuantiles
-