Package io.nosqlbench.api.engine.metrics
Class NicerHistogram
java.lang.Object
com.codahale.metrics.Histogram
io.nosqlbench.api.engine.metrics.NicerHistogram
- All Implemented Interfaces:
com.codahale.metrics.Counting,com.codahale.metrics.Metric,com.codahale.metrics.Sampling,DeltaSnapshotter,HdrDeltaHistogramAttachment,HdrDeltaHistogramProvider,HistogramAttachment
public class NicerHistogram
extends com.codahale.metrics.Histogram
implements DeltaSnapshotter, HdrDeltaHistogramAttachment, HistogramAttachment
-
Constructor Summary
ConstructorsConstructorDescriptionNicerHistogram(String metricName, DeltaHdrHistogramReservoir hdrHistogramReservoir) -
Method Summary
Modifier and TypeMethodDescriptionAttach a metric.com.codahale.metrics.HistogramattachHistogram(com.codahale.metrics.Histogram histogram) getDeltaSnapshot(long cacheTimeMillis) org.HdrHistogram.HistogramCreate a new interval histogram from the current data, then reset the histogram reservoir.Only return a new snapshot form current reservoir data if the cached one has expired.voidupdate(long value) Methods inherited from class com.codahale.metrics.Histogram
getCount, update
-
Constructor Details
-
NicerHistogram
-
-
Method Details
-
getDeltaReader
- Specified by:
getDeltaReaderin interfaceDeltaSnapshotter
-
getSnapshot
Only return a new snapshot form current reservoir data if the cached one has expired.- Specified by:
getSnapshotin interfacecom.codahale.metrics.Sampling- Overrides:
getSnapshotin classcom.codahale.metrics.Histogram- Returns:
- a new delta snapshot, or the cached one
-
getDeltaSnapshot
- Specified by:
getDeltaSnapshotin interfaceDeltaSnapshotter
-
attachHdrDeltaHistogram
Description copied from interface:HdrDeltaHistogramAttachmentAttach a metric.- Specified by:
attachHdrDeltaHistogramin interfaceHdrDeltaHistogramAttachment- Returns:
- the attached metric, after adding to the mirrors for the metric.
-
attachHistogram
public com.codahale.metrics.Histogram attachHistogram(com.codahale.metrics.Histogram histogram) - Specified by:
attachHistogramin interfaceHistogramAttachment
-
update
public void update(long value) - Overrides:
updatein classcom.codahale.metrics.Histogram
-
getNextHdrDeltaHistogram
public org.HdrHistogram.Histogram getNextHdrDeltaHistogram()Description copied from interface:HdrDeltaHistogramProviderCreate a new interval histogram from the current data, then reset the histogram reservoir.- Specified by:
getNextHdrDeltaHistogramin interfaceHdrDeltaHistogramProvider- Returns:
- the new interval histogram
-