Download tasks/afx-e2-s05/environment/workspace/monitoring/README.md from openenvforge/3ambench: direct link, hf CLI and curl.
- Browser
- Download file 6.83 kB
-
https://huggingface.co/datasets/openenvforge/3ambench/resolve/main/tasks/afx-e2-s05/environment/workspace/monitoring/README.md
- Command line
-
hf download hf://datasets/openenvforge/3ambench/tasks/afx-e2-s05/environment/workspace/monitoring/README.md
-
curl -L -o README.md https://huggingface.co/datasets/openenvforge/3ambench/resolve/main/tasks/afx-e2-s05/environment/workspace/monitoring/README.md
Fahrwerk Logistik monitoring
This is where Fahrwerk Logistik's alerting lives: the rules our Prometheus evaluates and the Alertmanager config every Prometheus in the company sends to. Observability owns it; teams ask for changes with LOG- tickets and review whatever touches their own rules. The platform and data Prometheus servers use the same Alertmanager, which is why many team subtrees route alerts this repo never fires.
Where things live
rules/: alerting and recording rules.alertmanager/alertmanager.yml: routing tree, receivers, inhibition rules.slo/services.yaml: the SLO catalog, the one place for targets, SLO windows, SLI families and traffic floors.teams/ownership.yaml: the team that owns each service. If a runbook disagrees, this file is right.docs/adr/: decisions (burn-rate policy, scrape intervals, disk alerts).runbooks/*.md: what each alert is for and how fast it has to page.incidents/: packets from past incidents (times: PagerDuty and postmortems win; Slack is local time and sometimes a minute out).tests/visible/: a smoke suite. Not a spec.
bin/af-check is CI (promtool check, the smoke tests, amtool check-config). bin/range2test turns a query_range pull from an incident packet into a promtool test so you can replay it against a branch.
Older files predate the conventions below; don't reformat them in passing. All groups run at the global evaluation interval (1m); we don't use interval:, query_offset: or limit: on groups. Rules don't read ALERTS or ALERTS_FOR_STATE (an alert keeping its own firing series up is the one exception we allow): when one alert should hold another back, that's an inhibition rule in Alertmanager, where on-call can see it.
The deploy job refuses a repo with symlinks in it, anywhere, so there are none: copy a file instead of linking it.
Scrape targets
This Prometheus scrapes our apps and the ingress. Every app target gets a service label from its Kubernetes Service name and a pod label at relabel time, so up{service="…"} is how you find a service's targets. kube-state-metrics and the kubelet live in the platform team's Prometheus, which we don't alert from. Platform federates a short allowlist of cAdvisor container series into ours (container_memory_*, container_spec_*, container_cpu_*) and nothing from kube-state-metrics. Synthetic checks run in the vendor's uptime tool, which only covers the public homepage. For us, up and the services' own request counters are the liveness signals.
Scrape intervals per job are in ADR 0002. We size rate windows at about four scrape intervals.
Severity and paging
page wakes someone up. critical is the older spelling of page: it routes and pages the same way, and new rules use page. warning pages nobody. Generation-1 files still have a few two-tier alerts with a warning and a critical copy.
We page when users are hurt now, or will be within the hour, and whoever gets paged can act on it. Everything else is a ticket (severity: ticket), which lands in the owning team's queue.
Kinds of alerts
| class | examples | goes to | rules |
|---|---|---|---|
| service | <ServiceCamel>HighErrorRatio, <ServiceCamel>Down, burn alerts |
owning team, paged | per service and never per pod (one page per service per outage); error alerts on a 5m window with for: 10m; errors are 5xx (4xx are the caller's problem) |
| capacity | ContainerMemoryNearLimit, disk |
owning team, ticket | an ADR can make a level page (disk: ADR 0011) |
| fleet | node, database, cache, broker exporters | infra, severity: warning |
pages nobody |
ContainerMemoryNearLimit means a container keeps reaching 90% of its memory limit for 10 minutes; a single busy 5-minute stretch doesn't count. The ticket should exist within 20 minutes of the first time the container reaches 90%, so there is time before the OOM kill. Alerts outside these classes keep their severity and team unless a ticket changes them, and ticket alerts carry service the way pages do.
All alerts: labels severity and team; service, capacity and ticket alerts add service (from the expression or as a static label); annotations summary (what is affected) and runbook_url.
Service health
Each service has one Down alert, <ServiceCamel>Down (checkout-api → CheckoutApiDown). It pages the owning team within 10 minutes of the service losing its last healthy target, including when the targets are gone. A restart that drops targets for up to 2 minutes must not page. Labels: severity: page, team, and service.
SLOs
SLI records are slo:sli_error:ratio_rate<window> for 5m, 30m, 1h and 6h: the bad fraction, by (service), covering every service that emits the family's metrics (don't filter them by service). Latency SLIs are per service (slo:sli_latency:ratio_rate<window>), because the objective is per service. Burn alerts only read the SLI records for their own service. Names: <ServiceCamel>ErrorBudgetBurnFast (for: 2m, severity: page) and <ServiceCamel>ErrorBudgetBurnSlow (for: 15m, severity: ticket), labels severity, team and slo: <service>-availability. The factors come from ADR 0007 and the window in the catalog.
Routing
Alerts are routed on their team label, which must be a team in teams/ownership.yaml. Every team has its own subtree, matched on team, that sends:
| alert severity | delivered to |
|---|---|
page or critical |
pagerduty-<team> + slack-<team> + slack-sre-fyi |
ticket |
jira-<team> + slack-<team> |
warning |
slack-<team> only |
slack-sre-fyi is #sre-fyi, where SRE sees every page; it pages nobody. Anything without a team ends up at the root receiver, slack-alerts-default, which nobody watches. Failed rule evaluations are routed to slack-prometheus-meta. We page per service: one page per service per outage, so two services down at once means two pages even when they belong to the same team. Leave other teams' receivers, global and time intervals alone (don't add any).
Inhibition
Inhibitions between service alerts use equal: [service]: an outage of one service must never mute another service's alerts. The critical copy of an alert holds back its warning copy, same alert and same service, with equal: [alertname, service].
Runbooks
Use https://runbooks.int.fahrwerk.example/alerts/<AlertName> as the runbook_url. The runbook site is built from runbooks/*.md, and the front matter of each page says which alerts it covers.
Changelog
- 2025-11: burn alerts moved to the SLI records (ADR 0007).
- 2026-02:
slack-sre-fyiadded; SRE stopped being paged for every team. - 2026-05: disk alerts per ADR 0011.
- 2026-08: kafka-exporter scraped every 1m instead of 15s (ADR 0002).