-
Notifications
You must be signed in to change notification settings - Fork 15
/
Copy pathsendgrid-prometheusrule.yaml
36 lines (36 loc) · 1.18 KB
/
sendgrid-prometheusrule.yaml
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
apiVersion: monitoring.coreos.com/v1
kind: PrometheusRule
metadata:
name: prometheus-exporter-sendgrid
spec:
groups:
- name: prometheus-exporter-sendgrid.rules
rules:
- alert: SendgridDown
expr: absent(sendgrid_delivered)
for: 5m
labels:
severity: critical
annotations:
message: "Sendgrid {{ $labels.prometheus_exporter }} is DOWN"
- alert: SendgridRequestsHigh
expr: sendgrid_requests > 10000
for: 5m
labels:
severity: warning
annotations:
message: "Sendgrid {{ $labels.prometheus_exporter }} requests emails is High above contracted plan"
- alert: SendgridSpamReportsHigh
expr: sendgrid_spam_reports > 100
for: 5m
labels:
severity: warning
annotations:
message: "Sendgrid {{ $labels.prometheus_exporter }} spam reports emails (marked as spam) is High"
- alert: SendgridBlocksHourlyRateHigh
expr: increase(sendgrid_blocks{}[1h]) > 20
for: 5m
labels:
severity: warning
annotations:
message: "Sendgrid {{ $labels.prometheus_exporter }}blocks hourly rate is High"