Module monitor_agent

Module monitor_agent 

Source
Expand description

System health monitor agent.

MonitorAgent polls all registered actors every POLL_INTERVAL_SECS seconds. If an actor’s last heartbeat exceeds TIMEOUT_SECS, an alert is broadcast to the MQTT system/health topic.

Like crate::main_actor::MainActor, the monitor is protected from external kill commands.

Structs§

ActorHealthReport
Health status of a single actor at a given point in time.
MonitorAgent
The health monitor actor.

Constants§

POLL_INTERVAL_SECS
How often the monitor sweeps all actors (seconds).
TIMEOUT_SECS
How many seconds without a heartbeat before an alert is raised (seconds).