Skip to main content

Module HealthStatus

Module HealthStatus 

Source
Expand description

§Health Status Monitoring

Component-level health tracking for IPC subsystems. The score is a deterministic aggregation of currently-tracked issues weighted by severity.

Layout (one export per file, file name = identity):

  • SeverityLevel::Enum - Low / Medium / High / Critical (ordered).
  • HealthIssue::Enum - tagged issue with Severity and Description accessors.
  • HealthMonitor::Struct - score + issue list + recovery counter.

TODO: zero callers as of 2026-05-02. IPC::StatusReporter defines its own HealthMonitor / HealthIssue with different shapes; the two should converge in a future batch.

Modules§

HealthIssue
Tagged health issue. Each variant carries a free-form description string; Severity and Description accessors normalise the tag→severity mapping in one place so the recalculation logic in HealthMonitor::Struct stays a pure aggregation.
HealthMonitor
Aggregate health monitor: a 0-100 score, the list of currently tracked issues (each paired with its severity for fast filtering), a recovery-attempt counter, and the timestamp of the last update. Recalculate derives the score deterministically from the issue list using the severity → penalty table: Low=5, Medium=15, High=25, Critical=40.
SeverityLevel
Health-issue severity ladder. Ordered Low → Medium → High → Critical so callers can compare with < / >. Drives the penalty applied to HealthMonitor::Struct::HealthScore.