Alerts are the bridge between observability and action. This episode covers the principles of actionable alerts, Grafana Alerting and alert rules, routing and grouping in the AlertManager style, recording rules, and best practices for maintaining alerts in production.

Observability isn't just about seeing problems — it's about detecting problems before users complain. This is alerting's role: connecting telemetry queries to notifications that trigger action.
This episode covers a healthy alerting strategy, the Grafana Alerting mechanism, the routing and grouping concepts in the AlertManager style, recording rules for expensive queries, and best practices so your team doesn't drown in alert fatigue.
A good alert answers three questions: what's wrong, how severe is it, and what should be done. An alert without a runbook is just noise.
what's wrong? how severe? what should be done?The three questions what's wrong? how severe? what should be done? are the first filter before creating a new alert.
An alert rule in Grafana is a query evaluated periodically:
sum(rate(http_requests_total{status=~"5.."}[5m])) /
sum(rate(http_requests_total[5m]))The query above computes the ratio of 5xx requests. The alert rule combines it with a condition, a for period, and a destination folder.
Grafana supports multi-dimensional alerts: one rule produces many alert instances, one per label combination. For example: the error rate rule above will create one alert per service that breaches the threshold.
for.for period.conditions:
- evaluator:
type: greater_than
params: [0.05]
for: 10mThe value for: 10m prevents alert flapping — the alert only fires when the error rate stays high for 10 consecutive minutes.
Routing determines where alerts are sent, grouping combines similar alerts into one notification:
route:
group_by: ["service"]
group_wait: 30s
group_interval: 5m
repeat_interval: 4h
routes:
- match:
severity: critical
receiver: on-call-pagerduty
- match:
severity: warning
receiver: slack-alertsThe rule match: severity: critical sends critical alerts to the PagerDuty on-call, while warnings are enough for Slack.
Recording rules compute heavy queries in advance and store them as new metrics:
groups:
- name: error_rate.rules
rules:
- record: job:http_errors:ratio5m
expr: sum(rate(http_requests_total{status=~"5.."}[5m])) by (job) /
sum(rate(http_requests_total[5m])) by (job)The metric job:http_errors:ratio5m can be used by alerts and dashboards without recomputing the heavy query — exactly the concept you saw in episode 7.
service:condition:severity, for example checkout:error-rate:critical.Warning
Alert fatigue is observability's silent enemy. A team receiving hundreds of false notifications will start ignoring all alerts — including the important ones. Fewer quality alerts are better than many noisy ones.
In episode 19 you understood the principles of actionable alerts, the Grafana Alerting mechanism with evaluation and state management, routing and grouping in the AlertManager style, recording rules for expensive queries, and best practices for maintaining alerts.
The key takeaways:
In the next episode 20 we'll discuss SLI, SLO, SLA, and error budgets — defining reliability indicators, setting targets, creating SLO dashboards and burn rate alerts, and managing error budgets as decision-making input. Alerting without reliability targets is just an alarm without direction.