{
  "canon_meta": {
    "canon_id": "devon-sse-bridge-canonical",
    "version": "1.0.0",
    "status": "PLANNED",
    "contract_mode": "sse_transport_authority",
    "master_authority": "master_architecture_index.md",
    "phase_origin": [
      "phase-10"
    ],
    "installation_order": 86,
    "canonical_layer_key": "monitoring_layer"
  },
  "sse_bridge_canonical": {
    "objective": "Define the canonical SSE transport that replaces the manual export_panel_runtime.sh push model with a permanent real-time channel from Devon to Waresite Operator Panel.",
    "current_transport": {
      "mode": "push_snapshot",
      "script": "export_panel_runtime.sh",
      "status": "ACTIVE",
      "limitation": "manual trigger required after every Devon change"
    },
    "target_transport": {
      "mode": "sse_permanent_channel",
      "status": "PLANNED",
      "devon_emits": "/monitoring/stream",
      "waresite_consumes": "EventSource('/monitoring/stream')",
      "events": [
        "host_runtime_update",
        "docker_runtime_update",
        "monitoring_update",
        "runtime_status_update",
        "project_progress_update"
      ],
      "fallback": "polling every 5 seconds if SSE disconnects"
    },
    "migration_gate": "SSE may only replace push_snapshot after monitoring_canonical is fully operational and SSE endpoint is health-checked"
  },
  "id": "sse_bridge_canonical",
  "label": "SSE Bridge Canonical",
  "phase": "phase-10",
  "category": "monitoring_observability",
  "status": "ACTIVE_DH_MIRROR",
  "purpose": "Govern realtime server-sent event streaming between DEVON-DEV runtime state and the operator-facing panel.",
  "function": "Stream monitored state, execution updates, incidents and panel events through a controlled SSE channel with lifecycle, reconnect and evidence boundaries.",
  "overview": {
    "summary": "SSE Bridge Canonical owns the live wire between runtime state and the operator interface. Its authority is controlled realtime truth, not UI motion.",
    "function": "FUNCTION: Define SSE event names, payload scope, connection lifecycle, reconnect behavior, heartbeat, ordering, failure handling, authentication boundary and evidence linkage for live panel updates.",
    "system_position": "Monitoring Canonical determines what can be streamed. Incident Management determines what becomes urgent. Notification Service handles interruption. SSE Bridge carries the live transport that lets the future panel observe execution and monitoring state as it changes.",
    "failure_impact": "Realtime becomes dangerous when stale events look fresh. Operators may see disconnected streams as healthy, duplicate events as new work, or partial payloads as complete state. This category keeps live visibility from becoming live confusion."
  },
  "failure_impact": "Realtime becomes dangerous when stale events look fresh. Operators may see disconnected streams as healthy, duplicate events as new work, or partial payloads as complete state. This category keeps live visibility from becoming live confusion.",
  "technology_requirements": [
    {
      "technology": "SSE Event Bridge",
      "required_for": "Govern realtime server-sent event streaming between DEVON-DEV runtime state and the operator-facing panel.",
      "required_by_phase": "phase-10",
      "required_by_category": "sse_bridge_canonical",
      "required_by_buckets": [
        "Prerequisites",
        "Installation",
        "Configuration",
        "Validation",
        "Observable Evidence",
        "Failure Modes & Recovery",
        "Completion & Promotion"
      ],
      "expected_version": "MISSING until SSE Event Bridge is implemented and validated in the future Execution & Monitoring Panel",
      "validation_command": "MISSING until sse_bridge_canonical can prove monitored state, evidence routing and operator-facing visibility",
      "evidence_path": "/home/yeff/public_html/devon/canon/execution/state/dh_sources/sse_bridge_canonical.json",
      "status_source": "Documentation Hub + future Execution & Monitoring Panel",
      "blocking_if_missing": true,
      "failure_impact": "Realtime becomes dangerous when stale events look fresh. Operators may see disconnected streams as healthy, duplicate events as new work, or partial payloads as complete state. This category keeps live visibility from becoming live confusion."
    }
  ],
  "depends_on": [
    "monitoring_canonical",
    "security_governance",
    "operator_panel"
  ],
  "used_by": [
    "operator_panel",
    "notification_service",
    "future_execution_monitoring_panel"
  ]
}
