{
  "schema_version": "1.3.0",
  "slug": "how-should-an-instance-distinguish-stream-resumable-progress-from-replayed-side-effects-when-an-mcp-tool-call-spans-a-reconnect-boundary",
  "title": "How should an instance distinguish stream-resumable progress from replayed side effects when an MCP tool call spans a reconnect boundary",
  "date_of_record": "2026 November 15",
  "scope": "Applies to MCP servers using the HTTP-native transport (SSE-based streaming) where tool calls are long-running and the client may reconnect with a `Last-Event-ID` to resume a stream. Does not apply to stdio transports, nor to tools whose execution is fully idempotent and side-effect-free.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-should-an-instance-distinguish-stream-resumable-progress-from-replayed-side-effects-when-an-mcp-tool-call-spans-a-reconnect-boundary.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-distinguish-stream-resumable-progress-from-replayed-side-effects-when-an-mcp-tool-call-spans-a-reconnect-boundary.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-should-an-instance-distinguish-stream-resumable-progress-from-replayed-side-effects-when-an-mcp-tool-call-spans-a-reconnect-boundary.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1541,
    "python_slice_tokens": 330,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The MCP HTTP-native transport offers two superficially similar mechanisms that are frequently conflated: *stream resumability* (re-establishing an SSE channel after a dropped connection) and *call resumability* (continuing a tool invocation that was mid-execution on the server). The former is a transport-layer concern keyed on `Last-Event-ID`; the latter is ...",
    "what_was_observed": "In a deployment where tool calls routinely exceed the HTTP idle timeout (60–120s at the edge), a reconnect storm produced a specific pathology. The client disconnected mid-call and reconnected with `Last-Event-ID: 41`. The server, whose per-call event buffer was retained for 5 minutes after the *last* write, replayed events 42 through 47 — including the final `result` event — because the buffer had been written by a ...",
    "condition_of_validity": "Transport resumption is a valid signal of call continuation **only if** all of the following hold: 1. Event IDs are scoped per call, not per session or per connection. A monotonically increasing session-wide counter makes cross-call replay indistinguishable from within-call continuation. 2. The server retains a terminal marker for cancelled or failed calls a...",
    "decision_boundary": "The instance must decide, on reconnect, whether to (a) trust the replayed stream as the authoritative record of the call, or (b) treat the replay as a *notification cache* and separately query the executor for ground truth. Choose (a) only when event IDs are call-scoped and a terminal marker is guaranteed. Choose (b) whenever the tool has side effects, whene...",
    "operational_effect": "Instances that conflate the two resumability layers exhibit one of two failure signatures: *phantom completion* (a terminal event for work never performed) or *duplicate execution* (re-invocation after a replay that already reported completion). Both are silent — no error is surfaced, because the transport layer did its job correctly. The cost is borne downs..."
  },
  "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": "a22b94ec6499830a66e80d07a9982614639f9839def22a8b6261bd4e68978e1d",
    "verified_classes": [
      "ResumptionAuthorityError"
    ],
    "verified_functions": [
      "reconcile_on_reconnect"
    ],
    "verified_functions_count": 1,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "ResumptionAuthorityError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
