382060f022
Phase 2 of the MCP 2026-07-28 migration (#69931), on top of the SDK 2.x migration (#88180): - Protocol-era negotiation (_negotiate_session): per-server `protocol` config key — auto (default, handshake-first with server/discover fallback on -32022/-32601), stateless (discover-first), legacy (handshake only). Auto is handshake-first deliberately: zero extra round-trips and zero behavior change for the entire existing server fleet, while 2026-07-28-only servers now connect via the fallback. All four transport call sites (stdio, SSE, new HTTP, legacy HTTP) route through the one choke point, so the CLI/desktop probe path inherits it too. - SEP-2549 list caching: tools/list ttlMs/cacheScope hints are captured during discovery and bound to the lazy-startup schema cache — TTL'd entries expire and force a live re-probe; hint-less (pre-2026) servers keep the never-expires behavior. Pagination continuation now speaks both SDK generations (params= vs cursor=). - SEP-837: OAuth client metadata declares application_type=native (config-overridable), with a fallback for 1.x-era metadata models. (RFC 9207 iss validation and SEP-2352 issuer-keyed credentials are native to SDK 2.0's OAuthClientProvider — verified, no client-side gap.) - SEP-2577 deprecation posture: SamplingHandler docstring marks the Sampling feature as upstream-deprecated (12-month window) — kept fully functional, closed to new capability. - Docs: `protocol` key in the MCP config reference.