Skip to content

Handle per-backend MCP revision in vMCP (client-side dual protocol) #5911

Closed

Description

@jhrozek

Part of #5756. Design: RFC THV-0083 (D6, Alternative 5, Phase 3); arch doc §"Client side: dual-protocol per backend" + §"Backend connection management".

Handle each backend according to its own negotiated revision (per-backend dual protocol), independent of the client edge.

Changes

  • Detect and cache each backend's negotiated era in the health/probe subsystem, keyed by backend ID — NOT a Revision field on the registry entry (the immutable registry is build-once and returns copies; only the operator writes the dynamic one).
  • Probe Modern-first (server/discover or a modern-shaped request), fall back to initialize only on a non-modern error; a Legacy handshake against a Modern-only backend is a guaranteed reject. Any backend-edge -32601/404/handshake rejection is a re-classification trigger (re-probe + retry under the corrected era). Note the era probe is a different request shape than the health ping, and ping is removed under Modern.
  • Give the backend Session (pkg/vmcp/session/internal/backend) a no-session mode — no initialize, no Mcp-Session-Id — for Modern backends; keep today's session-ful path for Legacy backends.
  • Per-request open/close connections first; the shared per-backend pool (zero-credential-state) is a measured follow-up.

Dependencies

#5909 (Phase 1 classifier wiring). Independent of the server-side Modern path issue.

Verification

  • Modern-first probe; stale-era re-classification on a mid-flight flip.
  • No-session Modern backend call (no initialize/Mcp-Session-Id).
  • The removed-ping health case (a Modern-only backend must not be pinged).
  • Legacy backend behavior unchanged.

Activity

  1. added
    needs-triage
    on Jul 22, 2026
  2. removed
    needs-triage
    on Jul 23, 2026
  3. self-assigned this
    on Jul 24, 2026
  4. jhrozek commented on Jul 24, 2026

    @jhrozek
    ContributorAuthor

    @JAORMX I saw this is assigned to you — I had a working client-side implementation ready, so I opened #5980 (now ready for review) rather than let it sit. It covers the outbound edge: per-backend Modern-vs-Legacy detection/caching, discover-based enumeration, the stateless call path, and re-probe/retry on a mid-flight revision flip, plus revision surfacing in status. Happy to hand it off, co-own, or just have you review — whatever works for you. I also filed #5979 for the missing VirtualMCPServer aggregation e2e (the current dual-era e2e only covers the proxy/server path).

  5. self-assigned this
    on Jul 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions