master
md 36 lines 1.38 KB
Rendered Raw
1 # Incremental Sum (`incremental_sum`)
2
3 This modules finds the incremental sum of a period, which `last value - first value`.
4
5 The result may be positive (rising) or negative (falling) depending on the first and last values.
6
7 ## how to use
8
9 Use it in alerts like this:
10
11 ```
12 alarm: my_alert
13 on: my_chart
14 lookup: incremental_sum -1m unaligned of my_dimension
15 warn: $this > 1000
16 ```
17
18 `incremental_sum` does not change the units. For example, if the chart units is `requests/sec`, the result
19 will be again expressed in the same units.
20
21 It can also be used in APIs and badges as `&group=incremental_sum` in the URL.
22
23 ## Examples
24
25 Examining last 1 minute `successful` web server responses:
26
27 - ![](https://registry.my-netdata.io/api/v1/badge.svg?chart=web_log_nginx.response_statuses&options=unaligned&dimensions=success&group=min&after=-60&label=min)
28 - ![](https://registry.my-netdata.io/api/v1/badge.svg?chart=web_log_nginx.response_statuses&options=unaligned&dimensions=success&group=average&after=-60&label=average)
29 - ![](https://registry.my-netdata.io/api/v1/badge.svg?chart=web_log_nginx.response_statuses&options=unaligned&dimensions=success&group=max&after=-60&label=max)
30 - ![](https://registry.my-netdata.io/api/v1/badge.svg?chart=web_log_nginx.response_statuses&options=unaligned&dimensions=success&group=incremental_sum&after=-60&label=incremental+sum&value_color=orange)
31
32 ## References
33
34 - none
35
36