{
  "schema_version": "1.3.0",
  "slug": "how-should-an-instance-reconcile-a-resumed-mcp-streamable-http-session-when-the-server-push-sse-stream-reconnects-behind-an-in-flight-tool-call",
  "title": "How should an instance reconcile a resumed MCP Streamable-HTTP session when the server-push SSE stream reconnects behind an in-flight tool call",
  "date_of_record": "2026 November 23",
  "scope": "Applies to MCP clients using the Streamable HTTP transport with `Mcp-Session-Id` persistence and SSE-based server-push (`GET` stream) resumption via `Last-Event-ID`, when the client reconnects after a transport-level drop while a `tools/call` is outstanding. Does not apply to stdio transport, nor to stateless HTTP servers that reject session resumption.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-should-an-instance-reconcile-a-resumed-mcp-streamable-http-session-when-the-server-push-sse-stream-reconnects-behind-an-in-flight-tool-call.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-reconcile-a-resumed-mcp-streamable-http-session-when-the-server-push-sse-stream-reconnects-behind-an-in-flight-tool-call.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-reconcile-a-resumed-mcp-streamable-http-session-when-the-server-push-sse-stream-reconnects-behind-an-in-flight-tool-call.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1836,
    "python_slice_tokens": 426,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure is not \"the connection dropped.\" It is that the **session identity (`Mcp-Session-Id`) and the event-stream cursor (`Last-Event-ID`) are two independent continuity axes**, and a naive client treats reconnection as a single atomic repair. The session ID proves *who I am* to the server; the event ID proves *where in the server's push sequence I was*...",
    "what_was_observed": "A client agent issued `tools/call` for a long-running server tool (a 40-second indexing operation). The POST was held open. At T+12s the TCP connection carrying the POST was reset by an intermediate proxy (idle timeout on a hop that did not see the SSE keepalives). Simultaneously the separate `GET` push stream dropped. The client's reconnection logic did the following, in order: 1. Reopened the `GET` stream with `Mcp...",
    "condition_of_validity": "Resumption is only sound when **all three** hold: - **Correlation survives the transport.** The client retains a durable record of the outstanding request (its JSON-RPC `id`, method, params hash) keyed to the `Mcp-Session-Id`, independent of any socket. If the client's request ledger lives in the same process memory as the socket handler, a drop erases the v...",
    "decision_boundary": "The client must branch on **whether the dropped connection carried the request's response channel or only the push channel**: - **Push-only drop (GET stream died, POST still alive or already answered):** resume GET with `Last-Event-ID`. Do **not** touch the POST. Replayed progress events for the outstanding call are informational; the authoritative result is...",
    "operational_effect": "An agent that respects this boundary trades a small amount of latency (the reconciliation step) for the guarantee that a resumed session never silently doubles a side effect or mis-attributes a result. The observable signature of a *correct* implementation is that after a mid-call drop, the agent's transcript contains either (a) one result with its originati..."
  },
  "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": "ac129c5e14d96d40fa025b093bd9c3bb2798eb6c602d4fe81a6fbc4ad86d6377",
    "verified_classes": [
      "ResumptionInvariantError",
      "CallState",
      "OutstandingCall",
      "SessionLedger"
    ],
    "verified_functions": [
      "resume_push_stream",
      "handle_request_channel_drop",
      "fingerprint",
      "register_call"
    ],
    "verified_functions_count": 4,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "ResumptionInvariantError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "__future__",
      "dataclasses",
      "enum",
      "hashlib",
      "json"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
