01 · The alert comes in
From wherever your alerts already live.
Every 15 minutes the assistant collects alerts from PagerDuty, from
Alertmanager (what is firing right now, with silences), and from
Prometheus alert history (which catches alerts that flap faster
than a page).
Each alert is handled once. If the same rule fires on twenty
filesystems, those collapse into one "this is widespread" case
instead of twenty investigations.
02 · Find what it is about
From alert labels to a file in git.
The alert's target (kind, namespace, name) is resolved from its
labels, and a snapshot of the live object and its git manifest is
fetched before the investigation starts. If the alert body is thin,
the rule definition itself is read.
If no tracked repository declares the workload, the outcome is
already known: an issue, never an edit to an unrelated file.
03 · Look at the pod
Describe, restart history, events.
The investigation is a loop of read-only tool calls against the
cluster. The pod's last state says OOMKilled, exit code 137,
seven restarts. Events confirm the pattern: back-off, restart,
back-off.
The cluster identity behind these tools can read. It cannot change
anything.
04 · Check the history
A range query shows the shape of the problem.
Memory working set over the last two days: it climbs every night
during the catalogue reload, touches the 512 MiB limit, and the
container is killed. Daytime use is well below.
That is not a leak (it drops back each time) and not random. It is
a known peak that no longer fits.
05 · Read the logs, if allowed
The previous container's last lines.
Where you have enabled log access for a cluster, the assistant reads
a short tail of the previous container, the one that died.
Here the last line before the kill is the catalogue reload with a
much larger item count than a year ago.
Without log access it does not guess. It says what it could not
see and hands you the command to look.
06 · The deciding question
Could a manifest change have prevented this?
Root cause: the catalogue grew, the reload's peak outgrew a memory
limit set long ago. A limit is a manifest value, so the answer is
yes, and the output is a draft MR.
Had the cause been outside git (a node problem, a workload in a
repository you do not track, a bug that needs a code change), the
answer would be no, and speculative "bump it just in case"
fixes are explicitly not allowed.
07 · Gates before it ships
Right workload, right kind of fix, real numbers.
Deterministic checks run on the drafted fix before anyone sees it:
- it edits the workload that alerted, not a similarly named one,
- the kind of change can address this class of alert (memory for an OOM, not a probe tweak),
- the file is actually applied by Flux, not an orphan,
- new memory values go through the same measured-usage clamps as right-sizing.
Anything that fails is held for human review with the reason named.
08 · Two possible outcomes
An MR when git can fix it. An issue when it cannot.
The MR carries the alert, the evidence trail and the reasoning. The
issue carries what was observed, the copy-paste commands to finish
the diagnosis, and the likely fix for each outcome.
The loop does not end at the proposal. An issue whose alert stays
quiet for long enough is closed with a note. A merged fix whose
alert keeps firing is escalated with a link back to the MR.