28.19. Perf

28.19.1. Description

Perf reduction function computes a single telemetry stream representing the values associated with a performance evaluation run for a given hostname.

28.19.2. Parameter

Table 28.18. 

ParameterDescriptionDefault
modeOne of 'MaxRequestMillis', 'MinRequestMillis', 'AvgRequestMillis', 'CorrectResponses' or 'IncorrectResponses'.AvgRequestMillis
hostNameThe host computer running the performance test, or '*' for all hosts*
testNameThe test name, or '*' for all tests.*

28.19.3. Example

Example 28.29. Performance

streams PerfStream(type, host, test) = {
   "Performance Data",
   Perf(type, host, test)
};

y-axis yAxis(label) = {label};

chart PerformanceChart(host, test) = {
  "Performance Results", 
  (PerfStream("MaxRequestMillis", host, test), yAxis("Milliseconds")),
  (PerfStream("MinRequestMillis", host, test), yAxis("Milliseconds")),
  (PerfStream("AvgRequestMillis", host, test), yAxis("Milliseconds"))
};

draw PerformanceChart("*", "FileMetricSensorDataBaseline-FileMetricSensorDataBaseline");

This charts shows an invocation of the Perf Reduction Function to compute the maximum, minimum, and average length of time in milliseconds required for execution of a performance test called "FileMetricSensorDataBaseline-FileMetricSensorDataBaseline".

This example reveals an interesting feature of the performance testing environment for this test and project: while the average performance on the test stays fairly steady between 300-500 milliseconds, and the minimum (i.e. best) value of performance is quite stable at around 250 milliseconds, the maximum (i.e. worst) value is qute variable, ranging from close to 250 milliseconds during one week to almost 10 times greater (2500 milliseconds) during others.