-
Notifications
You must be signed in to change notification settings - Fork 5
mcp: bump sse timeout & add support for streamable http #11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR raises the SSE client timeout to 30 seconds for slower services and adds support for a new StreamableHTTPMCPEndpoint to communicate over HTTP streaming with the same timeout.
- Increase SSE timeout in
mcp_clientto 30 seconds. - Introduce
StreamableHTTPMCPEndpointclass and handle it inmcp_client. - Export
StreamableHTTPMCPEndpointin the package’s__init__.py.
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| src/redpanda/agents/_mcp.py | Bumped SSE timeout, added StreamableHTTPMCPEndpoint and its branch in mcp_client. |
| src/redpanda/agents/init.py | Added StreamableHTTPMCPEndpoint to module exports. |
Comments suppressed due to low confidence (1)
src/redpanda/agents/_mcp.py:145
- There’s no test coverage for the new
StreamableHTTPMCPEndpointbranch inmcp_client. Consider adding unit tests to exercise this path.
elif isinstance(server, StreamableHTTPMCPEndpoint):
5 seconds is too low for slow services
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR bumps the SSE timeout to 30 seconds and adds support for streamable HTTP communication by introducing a new MCP endpoint.
- Bump SSE client timeout from the default to 30 seconds.
- Implement a new StreamableHTTPMCPEndpoint class using streamablehttp_client with a timedelta-based timeout.
- Update the module exports to include the new StreamableHTTPMCPEndpoint.
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| src/redpanda/agents/_mcp.py | Added StreamableHTTPMCPEndpoint and updated mcp_client to support it. |
| src/redpanda/agents/init.py | Exported StreamableHTTPMCPEndpoint. |
5 seconds is too low for slow services