public class LatencyStat
extends java.lang.Object
implements java.lang.Cloneable
Constructor and Description |
---|
LatencyStat(long maxTrackedLatencyMillis) |
Modifier and Type | Method and Description |
---|---|
Latency |
calculate()
Generated the min, max, avg, 95th and 99th percentile for the collected
measurements.
|
Latency |
calculateAndClear()
Generated the min, max, avg, 95th and 99th percentile for the collected
measurements, then clear the measurement collection.
|
void |
clear() |
boolean |
isEmpty() |
void |
rollup(LatencyStat other)
Add the measurement in "other" to the measurements held here, in order to
generate min, max, avg, 95th, 99th percentile for two Latency Stats.
|
void |
set(int numRecordedOps,
long nanoLatency)
Record a set of operations that took "nanolatency" long.
|
void |
set(long nanoLatency) |
java.lang.String |
toString() |
public void clear()
public Latency calculate()
public Latency calculateAndClear()
public void set(long nanoLatency)
public void set(int numRecordedOps, long nanoLatency)
public void rollup(LatencyStat other)
public boolean isEmpty()
public java.lang.String toString()
toString
in class java.lang.Object
Copyright (c) 2004-2012 Oracle. All rights reserved.