public class SamplingStatCalculator
extends java.lang.Object
addSample(SampleResult)
a few times, and pull
the stats out with whatever methods you prefer.Constructor and Description |
---|
SamplingStatCalculator() |
SamplingStatCalculator(java.lang.String label) |
Modifier and Type | Method and Description |
---|---|
Sample |
addSample(SampleResult res)
Records a sample.
|
void |
clear()
Clear the counters (useful for differential stats)
|
double |
getAvgPageBytes()
calculates the average page size, which means divide the bytes by number
of samples.
|
double |
getBytesPerSecond()
Throughput in bytes / second
|
long |
getCount() |
Sample |
getCurrentSample() |
java.util.Map<java.lang.Number,java.lang.Number[]> |
getDistribution() |
long |
getElapsed()
Get the elapsed time for the samples
|
long |
getErrorCount() |
double |
getErrorPercentage()
Returns the raw double value of the percentage of samples with errors
that were recorded.
|
double |
getKBPerSecond()
Throughput in kilobytes / second
|
java.lang.String |
getLabel() |
java.lang.Number |
getMax() |
double |
getMaxThroughput() |
double |
getMean() |
java.lang.Number |
getMeanAsNumber() |
java.lang.Number |
getMedian() |
java.lang.Number |
getMin() |
java.lang.Number |
getPercentPoint(double percent) |
java.lang.Number |
getPercentPoint(float percent) |
double |
getRate()
Returns the throughput associated to this sampler in requests per second.
|
double |
getSentBytesPerSecond()
Sent Throughput in bytes / second
|
double |
getSentKBPerSecond()
Sent Throughput in kilobytes / second
|
double |
getStandardDeviation() |
java.lang.String |
toString()
For debugging purposes, only.
|
public SamplingStatCalculator()
public SamplingStatCalculator(java.lang.String label)
public void clear()
public Sample getCurrentSample()
public long getElapsed()
public double getRate()
public double getBytesPerSecond()
public double getKBPerSecond()
public double getSentBytesPerSecond()
public double getSentKBPerSecond()
public double getAvgPageBytes()
public java.lang.String getLabel()
public Sample addSample(SampleResult res)
res
- the sample to recordpublic double getErrorPercentage()
public java.lang.String toString()
toString
in class java.lang.Object
public long getErrorCount()
public double getMaxThroughput()
public java.util.Map<java.lang.Number,java.lang.Number[]> getDistribution()
public java.lang.Number getPercentPoint(double percent)
public long getCount()
public java.lang.Number getMax()
public double getMean()
public java.lang.Number getMeanAsNumber()
public java.lang.Number getMedian()
public java.lang.Number getMin()
public java.lang.Number getPercentPoint(float percent)
public double getStandardDeviation()
Copyright © 1998-2019 Apache Software Foundation. All Rights Reserved.