mirror of
https://github.com/openai/codex.git
synced 2026-11-24 23:20:47 +00:00
Keep same-named MCP servers separate across environments (#60905)
## Why MCP servers discovered on different executors can share a name. Resolving them by name alone exposes only one server and prevents tools and resources from being addressed independently. ## What changed - Add the disabled-by-default `multi_environment_mcp` feature to expose environment-scoped servers, including multiple installations of the same plugin. - Carry exact `McpServerKey` identities through catalogs, connections, tool calls, resources, and approval tracking. Give environment-scoped tools stable namespaces derived from their environment. - Include `environment_id` in scoped resource listings and accept it in resource requests. Require it for environment-owned servers when multiple environments are selected. - Preserve server ownership through hooks and use the owning environment's permissions for scoped elicitation review. ## Testing Add coverage for same-named servers across environments, independent calls and approvals, resource selection, plugin discovery, and rejection of hook changes to the tool environment. GitOrigin-RevId: 5593372b06a15c16aa3220faa3b19f5d3b20e67e
This commit is contained in:
@@ -290,6 +290,8 @@ pub enum Feature {
|
||||
McpConnectionSharing,
|
||||
/// Defer optional stdio server startup in regular chats with a warm tool catalog.
|
||||
McpLazyStdioStartup,
|
||||
/// Keep same-named HTTP servers discovered on different executors separate.
|
||||
MultiEnvironmentMcp,
|
||||
/// Enable MCP protocol version 2026-07-28 for the host-owned Codex Apps server.
|
||||
CodexAppsMcp20260728,
|
||||
/// Let host-owned Apps catalog reads overlap the initial tool inventory.
|
||||
@@ -1760,6 +1762,12 @@ pub const FEATURES: &[FeatureSpec] = &[
|
||||
stage: Stage::UnderDevelopment,
|
||||
default_enabled: false,
|
||||
},
|
||||
FeatureSpec {
|
||||
id: Feature::MultiEnvironmentMcp,
|
||||
key: "multi_environment_mcp",
|
||||
stage: Stage::UnderDevelopment,
|
||||
default_enabled: false,
|
||||
},
|
||||
FeatureSpec {
|
||||
id: Feature::AppsEarlyResourceDiscovery,
|
||||
key: "apps_early_resource_discovery",
|
||||
|
||||
Reference in New Issue
Block a user