Skip to content

Make Streamable HTTP status mapping deterministic - #1797

Open
halter73 wants to merge 1 commit into
mainfrom
halter73-deterministic-http-headers
Open

Make Streamable HTTP status mapping deterministic#1797
halter73 wants to merge 1 commit into
mainfrom
halter73-deterministic-http-headers

Conversation

@halter73

@halter73 halter73 commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

Summary

  • remove the 250 ms deferred-header grace timer and its lifecycle/logging code
  • wait for the actual first JSON-RPC message on 2026-07-28 requests before committing headers, so SEP-2575 error-to-HTTP status mapping is deterministic under load
  • preserve eager response-header flushing for legacy protocol revisions
  • remove the new public callback overload and carry the ASP.NET Core response-start hook through an internal request-context feature
  • buffer SSE priming/polling writes until the first JSON-RPC message on the deferred path, keeping response start exactly-once under the transport lock

This intentionally leaves quiet 2026-07-28 handlers subject to the caller's HttpClient timeout unless they emit an inline message such as progress. It does not add StartResponseAsync; a Streamable HTTP-only API on RequestContext<T> needs a separate design.

Validation

  • dotnet build passes with 0 warnings and 0 errors
  • focused header/status regressions pass on .NET 8, 9, and 10
  • all in-repo test suites pass across their target frameworks
  • the external DockerEverythingServerTests.Sampling_Sse_EverythingServer remains environment-blocked because the configured running server does not expose trigger-sampling-request; the restored npm everything-server integration tests pass

Note

This pull request description was generated with GitHub Copilot.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant