-
Notifications
You must be signed in to change notification settings - Fork 147
Open
Labels
cliChanges that impact CLI functionalityChanges that impact CLI functionalitydocumentationImprovements or additions to documentationImprovements or additions to documentationenhancementNew feature or requestNew feature or requestgoPull requests that update go codePull requests that update go codeoperatorproxy
Description
Summary
Deprecate the SSE (Server-Sent Events) proxy mode for stdio transport in favor of streamable-http, which is the recommended MCP transport.
Background
The MCP specification has deprecated SSE transport in favor of streamable-http. While ToolHive currently supports both SSE and streamable-http proxy modes for stdio transport, we should deprecate the SSE proxy mode to align with the specification and reduce maintenance burden.
Current State
- ✅ The CLI (
thv run) defaults tostreamable-httpfor--proxy-modeflag - ✅ The operator defaults to
streamable-httpfor stdio transport - SSE proxy implementation exists in
pkg/transport/proxy/httpsse/http_proxy.go - Tests and documentation still reference SSE proxy mode
Proposed Deprecation Plan
-
Phase 1: Deprecation Notice
- Add deprecation warnings when SSE proxy mode is explicitly used
- Update documentation to mark SSE proxy mode as deprecated
- Update code comments to indicate deprecation
- Update help text for
--proxy-modeflag to indicate SSE is deprecated
-
Phase 2: Removal (Future)
- Remove SSE proxy mode support after a deprecation period
- Remove
pkg/transport/proxy/httpsse/package - Clean up related code and tests
- Remove
--proxy-modeflag entirely since there will only be one option (streamable-http)
Decision: Keep --proxy-mode Flag During Deprecation
Recommendation: Keep the flag during deprecation, then remove it after SSE support is removed.
Implementation during deprecation:
- Keep the flag but show deprecation warnings when
--proxy-mode sseis used - Default to
streamable-http(already done) - Make the flag optional (already done)
- Update help text to indicate SSE is deprecated
After SSE removal:
- Remove the flag entirely since there will only be one option
- Simplify code by removing proxy mode selection logic
Migration Path
Users currently using SSE proxy mode should:
- Update their configurations to use
--proxy-mode streamable-http(orproxyMode: streamable-httpin operator configs) - Update any scripts or automation that explicitly set SSE proxy mode
- Expect deprecation warnings if they continue using
--proxy-mode sseduring the deprecation period
Related Code
pkg/transport/stdio.go- Stdio transport implementation (defaults toProxyModeStreamableHTTP)pkg/transport/proxy/httpsse/http_proxy.go- SSE proxy implementation (to be removed)pkg/transport/types/transport.go- Proxy mode type definitionscmd/thv/app/run_flags.go:126- CLI flag defaults tostreamable-httpcmd/thv-operator/controllers/mcpserver_runconfig.go:126- Operator defaults tostreamable-httppkg/transport/factory.go:51- Factory sets proxy mode on stdio transport
References
- MCP Specification - Streamable HTTP
- Documentation:
docs/arch/03-transport-architecture.md(notes SSE is deprecated)
Metadata
Metadata
Assignees
Labels
cliChanges that impact CLI functionalityChanges that impact CLI functionalitydocumentationImprovements or additions to documentationImprovements or additions to documentationenhancementNew feature or requestNew feature or requestgoPull requests that update go codePull requests that update go codeoperatorproxy