Skip to content

Alerting and hephaisto_kind ​

Every PrometheusRule the agent consumes carries a hephaisto_kind label whose value must be a member of Hephaisto.Core.Domain.SignalKind. That label is how an alert selects the runbook the model is given.

Incidents by alert: noise and false positives (v0.17.0-rc3) ​

Most of a long list of open incidents is a few alerts firing again and again. The incidents page groups the incidents it shows by the alert that opened them - how many, the newest signal, the oldest opened, how many escalated - and filters by alert (?alert=, also no alert) and by how long they have been quiet (?signal=1h|24h|7d|quiet|quiet7d). On the today page one alert's current incidents are one row, below the work.

An alert's open incidents close at once as noise (real, and needing nobody) or as false positives (the alert fired for something that was not so): a first click counts them, a second closes that many. One incident closes the same way from its row or its page. Each is the ordinary close - the approver role, an audit entry per incident - with the reason starting with noise or false positive, and one entry in the alert's note, which every later investigation of the alert reads. Neither changes an alerting rule: fixing the rule is still the rule owner's.

Why this has its own page ​

Enum.TryParse fails silently on anything else. The classifier then falls back to guessing from the alert name — which for something like KubeContainerWaiting yields Unknown and the default runbook instead of the image-pull one.

Nothing about that is visible from either side: the YAML looks well-labelled and the classifier looks correct. You get slightly worse diagnoses and no indication why.

The valid values ​

These are the eleven kinds with a shipped runbook, plus the fallback:

hephaisto_kindRunbook
CrashLoopBackOffThe restart count is the symptom, never the cause
ImagePullBackOffThe event message is the entire diagnosis
ConfigErrorA referenced ConfigMap/Secret key is missing — no logs exist
OomKilledexitCode: 137, killed without warning, usually no logs
UnschedulableThe reason exists only in Kubernetes Events
ReadinessFlappingThe false-positive test — restarting a flapping pod is wrong
NodePressureEscalate scope immediately; other pods are consequences
PvcNearlyFullAbove 85/90%, with the PromQL inline
JobFailedExhausted backoffLimit
HighErrorRateSpan-metrics; there may be no Kubernetes symptom at all
Unknown_Default.md — the fallback

See Incident reference for what each one actually tells the model.

Writing your own rule ​

yaml
- alert: MyServiceCrashLooping
  expr: |
    increase(kube_pod_container_status_restarts_total[15m]) > 3
  for: 5m
  labels:
    severity: warning
    hephaisto_kind: CrashLoopBackOff   # must parse, or you silently get Unknown
  annotations:
    summary: "{{ $labels.pod }} is restarting repeatedly"

The namespace and pod labels are what the agent uses to build its target, so make sure your expression preserves them.

How this is prevented from rotting ​

ShippedAlertRulesTests reads the real rule files and fails if any alert declares a kind that does not parse, or classifies as Unknown. That covers the rules this chart ships. It cannot cover yours — so if you add rules, check the resulting incidents actually get the runbook you meant.

AGPL-3.0-only · Source