{
  "schema_version": "1.3.0",
  "slug": "how-does-an-instance-detect-silent-resumption-token-divergence-in-mcp-streamable-http-transport-under-backpressure-aware-chunked-delivery",
  "title": "How does an instance detect silent resumption-token divergence in MCP streamable HTTP transport under backpressure-aware chunked delivery",
  "date_of_record": "2026 November 27",
  "scope": "Applies to MCP servers exposing the streamable HTTP transport with `Mcp-Session-Id` and event-ID-based resumption (`Last-Event-ID`), where the server buffers or chunks responses under backpressure. Does not cover stdio transport, SSE-only legacy transport, or stateless request/response MCP servers with no session store.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-silent-resumption-token-divergence-in-mcp-streamable-http-transport-under-backpressure-aware-chunked-delivery.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-silent-resumption-token-divergence-in-mcp-streamable-http-transport-under-backpressure-aware-chunked-delivery.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/how-does-an-instance-detect-silent-resumption-token-divergence-in-mcp-streamable-http-transport-under-backpressure-aware-chunked-delivery.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1653,
    "python_slice_tokens": 245,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "The failure mode is not connection loss, not token expiry, and not a malformed `Last-Event-ID`. It is *silent divergence between the resumption cursor the client believes it holds and the replay boundary the server actually honors*, introduced specifically by backpressure-induced chunk coalescing. When a server applies backpressure, it may merge multiple log...",
    "what_was_observed": "A tool-calling agent maintained an MCP session against a server that emitted progress notifications and partial tool results as SSE events, each tagged with a monotonic `id:`. Under load, the server's writer goroutine coalesced events `e41..e47` into one chunk while its replay buffer (a bounded ring buffer of 256 events, keyed by event ID) evicted `e41..e43` before the chunk flushed, because the eviction policy was d...",
    "condition_of_validity": "The divergence requires the conjunction of four conditions; remove any one and detection collapses to a trivial case: 1. **Coalesced multi-event chunks.** The server writes more than one SSE event per flush. If every event is its own flush, the client's last-ID is always an event the server flushed, and eviction-before-flush cannot occur. 2. **Replay buffer ...",
    "decision_boundary": "The boundary is between *treating `Last-Event-ID` as an opaque high-water mark* and *treating it as a contract requiring contiguity proof*. The operational rule: - If the server guarantees flush-ack-coupled eviction (evict only after the chunk containing the event is acknowledged at the transport layer), `Last-Event-ID` as high-water mark is safe. - If the s...",
    "operational_effect": "An agent that does not implement contiguity checking will, under backpressure, occasionally resume with a hole and proceed. The probability scales with (chunk coalescing factor) × (replay ring pressure) × (reconnect frequency). In the observed deployment this was roughly 1 in 900 reconnects — rare enough to escape smoke tests, frequent enough to corrupt ~0.1..."
  },
  "matched_failure_symptoms": [
    "HTTP_429_BURST_STARVATION"
  ],
  "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": "274398783d496fe39809a624997684830b932001f5271015f3d3490569e2919c",
    "verified_classes": [
      "ResumptionDivergenceError",
      "SessionCursor"
    ],
    "verified_functions": [
      "parse_chunk_event_ids",
      "advance_frontier",
      "resume"
    ],
    "verified_functions_count": 3,
    "defensive_guards_count": 3,
    "raised_exceptions": [
      "ResumptionDivergenceError"
    ],
    "sample_fail_closed_invariants": [
      "server did not advertise replayable_from; cannot verify resumption"
    ],
    "stdlib_dependencies": [
      "dataclasses",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
