Kevin

Daemon Core — Boot & Event Dispatch

main.py → ServiceManager → EventBus → MQTT/SSE fanout.

Daemon Core — Boot & Event Dispatch (v2026-08-02T101544Z-ab2bbdebf5) 2026-08-01 | main.py → ServiceManager → EventBus → MQTT/SSE fanout. 1 - BOOTSTRAP - Daemon Initialization main.py python -m daemon setup_env(daemon_root) lan_autosetup(daemon_root) _bootstrap.py setup_env _mqtt_reachable lan_autosetup daemon startup… 2 - SERVICE MANAGEMENT - Core Services ServiceManager init_mesh_api get_event_bus load_plugins event_bus.py bus.publish() kv/events/# _lvc_writer_loop mesh API initi… 3 - EVENT DISPATCH - MQTT/SSE Fanout EventBus publish() mount_mqtt(mqtt_client) _lvc_writer_loop MQTT Broker localhost:1883 kv/events/# event publishi… 1. Start daemon with command 2. Load environment variables 3. Auto-setup LAN configuration 4. Initialize mesh API and eve… 5. Load core services and plug… 6. Publish events to MQTT brok… Sample Event Payload { "e": "holon:queued", "ts": 1672531200.0, "id": "uuid8-1234", "holon_id": "...", "to": "flynn" } MQTT Topic Structure kv/events/holon:queued kv/events/job:progress kv/events/ai:approval The MQTT broker connection is checked during bootstrap. If not reachable, the daemon operates in offline mode. Legend actor = initiates work · process = code path · store = state on disk · bus = durable queue · dashed = separate process cyan = request flow · pink = state read/write · dashed green = pull / return path · red = refusal

Provenance

This drawing is generated, not drawn. It is rebuilt from the source files below, so when they change the picture changes — a diagram here cannot quietly describe a system that no longer works this way.

Owner
Kevin
Slug
daemon-core
Rendered
2026-08-02T101544Z
From commit
ab2bbdebf5
Watches
4 paths
  • daemon/src/main.py
  • daemon/src/_bootstrap.py
  • daemon/src/event_bus.py
  • daemon/src/service_manager.py