Conversation
Signed-off-by: Hritik003 <hritik.raj@nutanix.com>
Signed-off-by: Hritik003 <hritik.raj@nutanix.com>
✅ Deploy Preview for theagentrouter canceled.
|
Signed-off-by: Hritik003 <hritik.raj@nutanix.com>
Signed-off-by: Hritik003 <hritik.raj@nutanix.com>
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
Signed-off-by: Hritik003 <hritik.raj@nutanix.com>
Signed-off-by: Hritik003 <hritik.raj@nutanix.com>
Signed-off-by: Hritik003 <hritik.raj@nutanix.com>
1. Kept the two separate helpers: - onErrorResponse(w, status, msg) — no id, code from status - onRequestError(w, status, code, msg, id) — echo id + explicit code Signed-off-by: Hritik003 <hritik.raj@nutanix.com>
|
/retest |
|
Nice work on this — the dual-era framing and the phased rollout in the proposal are the right call for a breaking wire-protocol change on a shared gateway. Two things I'd want resolved before merge, plus a couple of smaller notes. 1. func isLegacyVersion(v string) bool {
if len(v) != 10 || v[4] != '-' || v[7] != '-' { return false }
return v < protocolVersion20260728
}This accepts any date-shaped string lexicographically before 2. Backend-era verification isn't wired in yet, but this PR activates live dispatch on it The proposal's own Phase 1 acceptance criteria says activation "Depends on: PR 0.1 required; 0.2–0.4 required for a complete modern Cell 2" and should "require positive homogeneous backend-era evidence... before enabling the modern route." I don't see a detection := detectClientEra(r, rawMsg)
if detection.era == eraModern {
m.serveModernPOST(w, r, req, startAt)
}As written, a client that just adds Smaller:
|
Description
This PR continues modern MCP (2026-07-28) support by wiring era detection into the shared POST entrypoint and adding the remaining single-target modern handlers, plus dataplane coverage for the end-to-end path.
servePOST now classifies each request with detectClientEra and dispatches to the modern or legacy handler. Modern requests are validated against modern-only requirements (Mcp-Protocol-Version, Mcp-Method, _meta); legacy-only methods like initialize / ping are rejected on the modern path, and modern-only methods like server/discover are rejected on the legacy path.
On the modern path this adds single-target APIs
with backend selection from
Dataplane e2e coverage includes a modern test MCP server, a modern client helper, and tests for
Related Issues/PRs
Special notes for reviewers (if applicable)
Please focus review on:
Also note the concurrent ResponseRecorder fix in the subscriptions listen unit test (CI -race) and the legacy discover reject response echoing the JSON-RPC request id (needed for bench/direct Connect fallback).
Testing
Have documented all the testing scenarios in the doc - https://docs.google.com/document/d/1QwA6bvmMYghMBVP-AYvJ2NPWKQNzCHPXfdsrbe9pr3M/edit?usp=sharing
Has 3 suites of testing: