fix(mcp): serialize manager lifecycle operations - #4336
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8f0e6ebf65
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
8f0e6eb to
4db5a8d
Compare
|
Addressed in commit In parallel mode, The existing regression uses a task-bound server and asserts that overlapping cleanup performs exactly one cleanup, so it covers the reported ownership issue. Static AST parsing and |
|
Closing this PR in favor of #4340 ; your contribution credit is included in its commit. Thanks for reporting the issue and trying to resolve it. |
This pull request resolves #4334 by serializing the public MCPServerManager lifecycle operations.
When connect_all(), reconnect(), or cleanup_all() overlapped in parallel mode, multiple cleanup commands could be submitted to a per-server worker. The worker exited after the first cleanup, leaving later command futures unresolved and callers hanging.
This change:
Verification: