{"version":"2.1.317","anchor":"mcp-set-servers-can-now-be-queued-behind-a-turn","canonical_anchor":"mcp-set-servers-can-now-be-queued-behind-a-turn","heading":"MCP control requests in headless mode now run through a queue","tier":"notice","area":"SDK","scope":"individual","heads_up":true,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.317\/e\/mcp-set-servers-can-now-be-queued-behind-a-turn","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.317","markdown":"### MCP control requests in headless mode now run through a queue\n\nIn headless and SDK use, `mcp_set_servers` and `mcp_reconnect` requests now go through a queue beside the main loop instead of running inline\n\n**What**\n\nIn headless mode, a program drives Claude Code without its usual screen, for example through the SDK. That program can send control requests to change MCP servers (add-ons that supply extra tools). How those requests run has changed:\n\n- A new queue runs MCP control requests such as `mcp_set_servers` and `mcp_reconnect` beside the main loop.\n\n- `mcp_set_servers` no longer waits inline. It goes through the queue, its response carries `heldLoop`, and its errors are logged only in some modes.\n\n- `mcp_reconnect` can now wait behind other work instead of running inline.\n\n- In the `reload_plugins` output, `mcpServers` now comes from a different source, and `dynamicMcpConfig` is passed to the check of how a change affects the cache.\n\n- Records of an interrupt now include the messages that were cancelled.\n\n**Why**\n\nIf you build on the SDK, the timing of MCP server updates and reconnects may look different, because they now wait their turn in a queue rather than running at the moment the request arrives.\n\n- Area: SDK\n- Names: `mcp_set_servers`\n- Tier: You'll notice\n- Useful: 2\/5\n- Signal: 3\/5\n- Scope: individual\n- Heads-up: yes"}