ARM 4.0 gauge metric
[ARM 4.0 Metrics]
A gauge value can go up and down, and it can be positive or negative. More...
Data Structures | |
struct | arm_metric_gaugedivr32 |
32-bit integer plus a 32-bit divisor, used to simulate floating-point gauge. More... | |
Typedefs | |
typedef arm_int32_t | arm_metric_gauge32_t |
32-bit integer metric gauge type | |
typedef arm_int64_t | arm_metric_gauge64_t |
64-bit integer metric gauge type | |
typedef struct arm_metric_gaugedivr32 | arm_metric_gaugedivr32_t |
32-bit integer plus a 32-bit divisor, used to simulate floating-point gauge. |
Detailed Description
A gauge value can go up and down, and it can be positive or negative.
This is the IETF RFC 1155 definition of a gauge.
A gauge should be used instead of a counter when it is not meaningful to sum up the values over an interval. An example is the amount of memory used. If the amount of memory used over 20 transactions in an interval is measured and the average usage for each of these transactions was 15MB, it does not make sense to say that 20*15=300MB of memory were used over the interval. It would make sense to say that the average was 15MB, that the median was 12MB, and that the standard deviation was 8MB. The values can be averaged, maximums and minimums per transaction calculated, and other kinds of statistical calculations performed.
ARM supports three gauge types:
Processing multiple values of the same counter
Gauges can be set before arm_start_transaction(), arm_update_transaction(), and arm_stop_transaction() calls. This creates the potential for different interpretations. If several values are provided for a transaction [e.g., one at arm_start_transaction(), one at each arm_update_transaction(), and one at arm_stop_transaction()], which one(s) should be used? In order to have consistent interpretation, the following conventions apply. Measurement agents are free to process the data in any way within these guidelines.
- The maximum value for a transaction will be the largest valid value passed at any time between and including the arm_start_transaction() and arm_stop_transaction() calls.
- The minimum value for a transaction will be the smallest valid value passed at any time between and including the arm_start_transaction() and arm_stop_transaction() calls.
- The mean value for a transaction will be the mean of all valid values passed at any time between and including the arm_start_transaction() and arm_stop_transaction() calls. All valid values will be weighted equally each time a arm_start_transaction(), arm_update_transaction(), or arm_stop_transaction() executes.
- The median value for a transaction will be the median of all valid values passed at any time during the transaction. All valid values will be weighted equally each time a arm_start_transaction(), arm_update_transaction(), or arm_stop_transaction() executes.
- The last value for a transaction will be the last valid value passed whenever any arm_start_transaction(), arm_update_transaction(), or arm_stop_transaction() executes.