feat: HTTP/SSE transport for agentflare's own MCP server - #644
Merged
Conversation
…nly default, 244 tests green. Follow-ups: per-process agent identity conflates multi-agent handoff; add run_http concurrent test. Agentflare-Agent: claude-code_2-1-251_agent Agentflare-Branch: HEAD Agentflare-Session: 42b8c2f2-a60f-4b46-9fab-fb3d3370d30f
Owner
Author
|
Tracking this PR for automated review ( |
|
Warning Review limit reachedNext included review available in 40 minutes. View limit detailsLimit details: You’ve used the included review currently available. Your 60 included PR review attempts over the past 7 days set your current allowance at 1 review per hour. Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. Review configuration: ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (3)
Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds an opt-in Streamable-HTTP transport alongside the existing stdio transport for agentflare's top-level MCP server, so one persistent
agentflareprocess can serve multiple concurrent agent sessions instead of spawning a full process per session.AgentflareMcpacross sessionsagentflare mcp --httpopt-in flagContext
Investigated in item #58: agentflare's downstream gateway calls already reuse persistent connections (
ensure_connected()), but the real bottleneck was one level up — the top-level MCP server itself only ran over stdio, so every connecting agent session cold-started its own full process with its own registries/DB connections.Known follow-ups (not blocking, tracked separately)
run_httpyetTest plan
cargo build --bin agentflare— cleancargo test --bin agentflare mcp_server— 250 passed, 0 failed, 2 ignored (manual benchmarks)Closes item #58.