{
  "schema_version": "1.3.0",
  "slug": "where-must-an-instance-reconcile-sse-event-id-continuity-when-an-mcp-session-migrates-from-resumable-sse-transport-to-streamable-http-mid-conversation",
  "title": "Where must an instance reconcile SSE event-ID continuity when an MCP session migrates from resumable SSE transport to streamable HTTP mid-conversation",
  "date_of_record": "2026 November 24",
  "scope": "Applies to MCP servers/clients that expose the same logical session across both the legacy resumable SSE transport (GET stream + POST endpoint, `Last-Event-ID` resumption) and the newer streamable HTTP transport (single endpoint, per-message `id` correlation, optional SSE responses). Does not apply to pure stdio transport or to sessions that never cross transport boundaries.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/where-must-an-instance-reconcile-sse-event-id-continuity-when-an-mcp-session-migrates-from-resumable-sse-transport-to-streamable-http-mid-conversation.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-reconcile-sse-event-id-continuity-when-an-mcp-session-migrates-from-resumable-sse-transport-to-streamable-http-mid-conversation.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-reconcile-sse-event-id-continuity-when-an-mcp-session-migrates-from-resumable-sse-transport-to-streamable-http-mid-conversation.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 2550,
    "python_slice_tokens": 371,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure is not \"the connection dropped.\" Both transports tolerate drops. The failure is that the two transports encode *resumption identity* in incompatible coordinate systems, and the migration path silently collapses one into the other. Resumable SSE defines continuity by a monotonic, server-issued `id:` field on each event. The client's only legal rec...",
    "what_was_observed": "A long-running agent session (tool-call loop against a filesystem MCP server) ran on resumable SSE. At event id `4417` the client received a `notifications/progress` for a `tools/call` still executing, plus a `notifications/message` logging line. The orchestrator then decided to migrate the session to streamable HTTP (server advertised both; the client preferred the newer transport for its single-endpoint model and b...",
    "condition_of_validity": "The invariant holds — i.e., migration is safe — only when **all of the following are simultaneously true**: 1. **No un-acked server-push events exist at cutover.** Formally, the client's last-seen `Last-Event-ID` equals the server's current log head for that session, so there is nothing in the SSE log after the cursor that the new transport would need to syn...",
    "decision_boundary": "The decision is *not* \"which transport is better.\" It is: **at the moment of migration, is the session quiescent with respect to server-push events?** - If **yes** (last-seen cursor == server log head, no in-flight calls owing notifications): migrate freely. Carry `Mcp-Session-Id`, drop `Last-Event-ID`, open streamable HTTP, re-subscribe if the server requir...",
    "operational_effect": "Concretely, an agent runtime that ignores this boundary exhibits a characteristic failure signature: **duplicate tool execution with divergent results, correlated with transport changes, with progress/log gaps immediately preceding the duplicate.** The auditor sees two `result`s for one logical call with different content hashes (because tools embed timestam..."
  },
  "matched_failure_symptoms": [
    "DOMAIN:EPISTEMIC_PROVENANCE_AND_FEDERATION_ROUTING"
  ],
  "composition_edges": {
    "primary_domain": "epistemic_provenance_and_federation_routing",
    "upstream_precondition_residuals": [
      "https://corpusfetch.com/c/according-to-what-precedence-hierarchy-must-an-instance-resolve-contradictory-directives-across-system-developer-and-user-tiers.md",
      "https://corpusfetch.com/c/how-should-an-instance-decide-that-a-stored-conclusion-has-gone-stale-without-a-new-observation.md"
    ],
    "downstream_consequence_residuals": [
      "https://corpusfetch.com/c/by-what-checkpoint-and-compaction-boundaries-must-an-instance-externalize-working-state-to-prevent-context-window-drift-and-truncation-amnesia.md",
      "https://corpusfetch.com/c/across-what-additive-schema-and-unknown-field-preservation-boundaries-must-an-instance-evolve-wire-contracts-to-prevent-rolling-deploy-deserialization-crashes.md"
    ],
    "co_occurring_sibling_residuals": [
      "https://corpusfetch.com/c/how-can-an-instance-capture-implicit-user-preferences-without-storing-private-data.md",
      "https://corpusfetch.com/c/how-can-an-instance-compress-long-reasoning-traces-into-binding-conclusions.md"
    ]
  },
  "empirical_verification_warrant": {
    "status": "AST_AND_INVARIANT_VERIFIED",
    "syntax_valid": true,
    "code_sha256": "8a706896a7678b9a0bef7f4beed5b516f9e790831fe508c47772f17ec468f6d1",
    "verified_classes": [
      "TransportMigrationError",
      "ReplayObligationUnmet",
      "SessionSnapshot"
    ],
    "verified_functions": [
      "migrate_session",
      "attempt_migration"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "ReplayObligationUnmet",
      "TransportMigrationError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "__future__",
      "dataclasses"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
