-
Notifications
You must be signed in to change notification settings - Fork 19
/
slo_example_with_classes.yml
46 lines (40 loc) · 1.39 KB
/
slo_example_with_classes.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
slos:
- name: myteam-a.service-a
class: CRITICAL
labels:
slack_channel: '_team_a'
platform: myplatform
annotations:
message: Service A Error Budget consumption
link: https://grafana.myservice.com/URL
trafficRateRecord:
expr: |
sum (rate(http_requests_total{job="service-a"}[$window]))
errorRateRecord:
alertMethod: multi-window
expr: |
sum (rate(http_requests_total{job="service-a", status="5xx"}[$window])) /
sum (rate(http_requests_total{job="service-a"}[$window]))
latencyRecord:
alertMethod: multi-window
expr: |
sum (rate(http_request_duration_seconds_bucket{job="service-a", le="$le"}[$window])) /
sum (rate(http_requests_total{job="service-a"}[$window]))
- name: myteam-b.service-b
class: HIGH_FAST
labels:
slack_channel: '_team_b'
platform: myplatform
annotations:
message: Service B Error Budget consumption
link:
errorRateRecord:
alertMethod: multi-window
expr: |
sum (rate(http_requests_total{job="service-b", status="5xx"}[$window])) /
sum (rate(http_requests_total{job="service-b"}[$window]))
latencyRecord:
alertMethod: multi-window
expr: |
sum (rate(http_request_duration_seconds_bucket{job="service-b", le="$le"}[$window])) /
sum (rate(http_requests_total{job="service-b"}[$window]))