{
  "schema_version": "1.3.0",
  "slug": "where-must-an-instance-stop-trusting-mcp-sse-resumption-the-last-event-id-replay-gap-under-backpressure-drop",
  "title": "Where must an instance stop trusting MCP SSE resumption: the `Last-Event-ID` replay gap under backpressure drop",
  "date_of_record": "2026 November 12",
  "scope": "Applies to MCP servers using the HTTP-native transport with `text/event-stream` streaming and `Last-Event-ID`-based session resumption, specifically when the server enforces per-connection backpressure by dropping or coalescing outbound events. Does not apply to stdio transports, nor to SSE implementations that buffer unbounded per-session event logs and never drop.",
  "projections": {
    "unified_markdown_uri": "https://corpusfetch.com/c/where-must-an-instance-stop-trusting-mcp-sse-resumption-the-last-event-id-replay-gap-under-backpressure-drop.md",
    "method_python_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-stop-trusting-mcp-sse-resumption-the-last-event-id-replay-gap-under-backpressure-drop.py",
    "remnant_warrant_slice_uri": "https://corpusfetch.com/c/where-must-an-instance-stop-trusting-mcp-sse-resumption-the-last-event-id-replay-gap-under-backpressure-drop.warrant.json"
  },
  "token_profile": {
    "full_markdown_tokens": 1636,
    "python_slice_tokens": 313,
    "warrant_slice_tokens": 220
  },
  "remnant_summary": {
    "core_distinction": "There are two distinct notions of \"resumable\" that the MCP HTTP-native transport spec conflates at the wire level but which diverge sharply under load: 1. **Session resumability** — the server retains the session object (tools, resources, sampling state) and will accept a reconnect with the same `Mcp-Session-Id`. 2. **Event-stream resumability** — the server...",
    "what_was_observed": "A tool-invocation stream that emitted progress notifications (`notifications/progress`) followed by a terminal `result` for a long-running operation. Under a slow consumer (a client whose read loop was blocked on a downstream write), the server's per-connection buffer filled. The server's backpressure policy was to drop *intermediate* progress notifications while preserving the terminal message. This is a reasonable ...",
    "condition_of_validity": "`Last-Event-ID` resumption is only sound when **all** of the following hold: - The server's event log for the session is gapless from the client's last acknowledged ID to the current head, **or** the server emits an explicit gap/`resync` signal that the client is contractually required to handle by discarding accumulated state and re-fetching. - Dropped even...",
    "decision_boundary": "A client (or an agent operating one) must treat the following as the decision point: - **Trust resumption** (replay and continue) only if the server has, out-of-band or in its capability declaration, asserted gapless event retention for the session lifetime, and the client has observed no drop-indicating signal. - **Distrust resumption and force resync** whe...",
    "operational_effect": "In practice this means MCP clients using HTTP-native streaming must maintain a per-session flag: `stream_is_lossless`. It is set false on any reconnect, on any detected buffer-pressure signal, or when the server's capabilities do not declare gapless retention. While false, cumulative notifications are treated as advisory and the authoritative result is obtai..."
  },
  "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": "9b2b5bd5b554c2d3fc12032c052de837479d258e8888898807be3e6b68b3ad62",
    "verified_classes": [
      "LossyResumptionError",
      "StreamState"
    ],
    "verified_functions": [
      "resume_stream",
      "finalize"
    ],
    "verified_functions_count": 2,
    "defensive_guards_count": 2,
    "raised_exceptions": [
      "LossyResumptionError"
    ],
    "sample_fail_closed_invariants": [],
    "stdlib_dependencies": [
      "dataclasses",
      "hashlib",
      "typing"
    ],
    "observation_mode": "EMPIRICAL_BOUNDARY_CAPTURE",
    "zero_external_deps": true
  }
}
