Package com.yahoo.container.jdisc.state
Class MetricSnapshot
java.lang.Object
com.yahoo.container.jdisc.state.MetricSnapshot
- All Implemented Interfaces:
Iterable<Map.Entry<MetricDimensions,MetricSet>>
public final class MetricSnapshot
extends Object
implements Iterable<Map.Entry<MetricDimensions,MetricSet>>
A snapshot of the metrics of this system in a particular time interval.
- Author:
- Simon Thoresen Hult
-
Constructor Summary
ConstructorsConstructorDescriptionMetricSnapshot(long from, long to, TimeUnit unit, Map<MetricDimensions, MetricSet> data) -
Method Summary
Modifier and TypeMethodDescriptionCreate a new snapshot instance where Gauge metrics are preserved with the last-values they have in this snapshot instance.longgetFromTime(TimeUnit unit) longiterator()Returns all the metrics in this snapshot.Returns a metric set from this snapshot for a given set of dimensionsMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
MetricSnapshot
-
-
Method Details
-
getFromTime
-
getToTime
-
iterator
Returns all the metrics in this snapshot.- Specified by:
iteratorin interfaceIterable<Map.Entry<MetricDimensions,MetricSet>>
-
metricSet
Returns a metric set from this snapshot for a given set of dimensions -
createSnapshot
Create a new snapshot instance where Gauge metrics are preserved with the last-values they have in this snapshot instance.
-