Class NBMetricHistogram
java.lang.Object
com.codahale.metrics.Histogram
io.nosqlbench.nb.api.engine.metrics.instruments.NBMetricHistogram
- All Implemented Interfaces:
com.codahale.metrics.Counting,com.codahale.metrics.Metric,com.codahale.metrics.Sampling,DeltaSnapshotter,HdrDeltaHistogramAttachment,HdrDeltaHistogramProvider,HistogramAttachment,NBMetric,NBLabeledElement
public class NBMetricHistogram
extends com.codahale.metrics.Histogram
implements DeltaSnapshotter, HdrDeltaHistogramAttachment, HistogramAttachment, NBMetric
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.nosqlbench.nb.api.labels.NBLabeledElement
NBLabeledElement.BasicLabeledElement -
Field Summary
Fields inherited from interface io.nosqlbench.nb.api.labels.NBLabeledElement
EMPTY -
Constructor Summary
ConstructorsConstructorDescriptionNBMetricHistogram(NBLabels labels, DeltaHdrHistogramReservoir hdrHistogramReservoir, String description, MetricCategory... categories) NBMetricHistogram(String name, DeltaHdrHistogramReservoir hdrHistogramReservoir, String description, MetricCategory... categories) -
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.toString()typeName()voidupdate(long value) Methods inherited from class com.codahale.metrics.Histogram
getCount, updateMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface io.nosqlbench.nb.api.labels.NBLabeledElement
description
-
Constructor Details
-
NBMetricHistogram
public NBMetricHistogram(NBLabels labels, DeltaHdrHistogramReservoir hdrHistogramReservoir, String description, MetricCategory... categories) -
NBMetricHistogram
public NBMetricHistogram(String name, DeltaHdrHistogramReservoir hdrHistogramReservoir, String description, MetricCategory... categories)
-
-
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
-
getLabels
- Specified by:
getLabelsin interfaceNBLabeledElement
-
typeName
-
getDescription
- Specified by:
getDescriptionin interfaceNBMetric
-
getCategories
- Specified by:
getCategoriesin interfaceNBMetric
-
toString
-