com.sun.faban.driver.engine
Class RuntimeMetrics

java.lang.Object
  extended by com.sun.faban.driver.engine.RuntimeMetrics
All Implemented Interfaces:
PairwiseAggregator.Aggregable<RuntimeMetrics>, Serializable

public class RuntimeMetrics
extends Object
implements Serializable, PairwiseAggregator.Aggregable<RuntimeMetrics>

The runtime metrics is used for communicating runtime stats from the agents to the master.

Author:
akara
See Also:
Serialized Form

Field Summary
static int C_ERRORS
          Index for current error rate label.
static int C_RESP
          Index for current response time label.
static int C_RESP90
          Index for current 90th% response time label.
static int C_SD
          Index for current standard deviation label.
static int C_THRUPUT
          Index for current thruput label.
protected  long coarseRespBucketSize
          Size of the coarse response time buckets.
protected  long coarseRespHistMax
          Max coarse response time.
protected  int[] errCntStdy
          Number of failed transactions during steady state.
protected  int[] errCntTotal
          Number of failed transactions total.
protected  long fineRespBucketSize
          Size of the fine response time buckets.
protected  long fineRespHistMax
          Max fine response time.
protected  double[] hiRespSumStdy
          Sum of the overflow response time.
static String[] LABELS
          The output labels for the runtime metrics.
static int O_RESP
          Index for overall response time label.
static int O_RESP90
          Index for overall 90th% response time label.
static int O_SD
          Index for overall standard deviation label.
static int O_THRUPUT
          Index for overall thruput label.
protected  int[][] respHist
          Response time histogram.
protected  double[] respSumStdy
          Sum of response times during steady state.
protected  double[] respSumTotal
          Sum of response times total.
protected  double[] sumSquaresStdy
          The sum squares of the deviations in steady state.
protected  double[] sumSquaresTotal
          The sum squares of the deviations total.
protected  int[] txCntStdy
          Number of successful transactions during steady state.
protected  int[] txCntTotal
          Number of successful transactions total.
 
Method Summary
 void add(Metrics m)
          Adds a metrics to this RuntimeMetrics.
 void add(RuntimeMetrics m)
          Adds a metrics to this RuntimeMetrics.
 void copy(Metrics m)
          Copies the necessary members of Metrics into this RuntimeMetrics.
 double[][] getResults(RunInfo runInfo, RuntimeMetrics prev)
          Synthesizes and provides the results from this runtime stats.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

C_THRUPUT

public static final int C_THRUPUT
Index for current thruput label.

See Also:
Constant Field Values

O_THRUPUT

public static final int O_THRUPUT
Index for overall thruput label.

See Also:
Constant Field Values

C_ERRORS

public static final int C_ERRORS
Index for current error rate label.

See Also:
Constant Field Values

C_RESP

public static final int C_RESP
Index for current response time label.

See Also:
Constant Field Values

O_RESP

public static final int O_RESP
Index for overall response time label.

See Also:
Constant Field Values

C_SD

public static final int C_SD
Index for current standard deviation label.

See Also:
Constant Field Values

O_SD

public static final int O_SD
Index for overall standard deviation label.

See Also:
Constant Field Values

C_RESP90

public static final int C_RESP90
Index for current 90th% response time label.

See Also:
Constant Field Values

O_RESP90

public static final int O_RESP90
Index for overall 90th% response time label.

See Also:
Constant Field Values

LABELS

public static final String[] LABELS
The output labels for the runtime metrics.


fineRespBucketSize

protected long fineRespBucketSize
Size of the fine response time buckets.


coarseRespBucketSize

protected long coarseRespBucketSize
Size of the coarse response time buckets.


fineRespHistMax

protected long fineRespHistMax
Max fine response time.


coarseRespHistMax

protected long coarseRespHistMax
Max coarse response time.


txCntStdy

protected int[] txCntStdy
Number of successful transactions during steady state. This is used for final reporting and in-flight reporting of averages.


txCntTotal

protected int[] txCntTotal
Number of successful transactions total. This is used for in-flight reporting only.


errCntStdy

protected int[] errCntStdy
Number of failed transactions during steady state. This is used for final reporting and in-flight reporting of averages.


errCntTotal

protected int[] errCntTotal
Number of failed transactions total. This is used for in-flight reporting only.


respSumStdy

protected double[] respSumStdy
Sum of response times during steady state.


respSumTotal

protected double[] respSumTotal
Sum of response times total.


hiRespSumStdy

protected double[] hiRespSumStdy
Sum of the overflow response time.


sumSquaresStdy

protected double[] sumSquaresStdy
The sum squares of the deviations in steady state.


sumSquaresTotal

protected double[] sumSquaresTotal
The sum squares of the deviations total.


respHist

protected int[][] respHist
Response time histogram.

Method Detail

copy

public void copy(Metrics m)
Copies the necessary members of Metrics into this RuntimeMetrics.

Parameters:
m - The metrics to copy

add

public void add(Metrics m)
Adds a metrics to this RuntimeMetrics.

Parameters:
m - The metrics to add

add

public void add(RuntimeMetrics m)
Adds a metrics to this RuntimeMetrics.

Specified by:
add in interface PairwiseAggregator.Aggregable<RuntimeMetrics>
Parameters:
m - The metrics to add

toString

public String toString()
Overrides:
toString in class Object

getResults

public double[][] getResults(RunInfo runInfo,
                             RuntimeMetrics prev)
Synthesizes and provides the results from this runtime stats. The results are first indexed by the stat type, then by the tx type.

Parameters:
runInfo - The RunInfo for this benchmark run
prev - The previous RuntimeMetrics
Returns:
The synthesized results