Repository navigation
Conversation
- mcp_http.threads (read-only, default 4): I/O workers; each serves one call at a time (the spike had one). Router assigns connections to the workers in turn. - mcp_http.max_sessions_per_account (read-only, default 4): caps an account's concurrent endpoint sessions (error 1203), since the server's max_user_connections does not apply to command-service sessions. - Sessions are subject to max_connections (MYSQL_COMMAND_BYPASS_MAX_CONNECTIONS = false, 26.10) instead of bypassing it (error 1040 when full). test-mcp-endpoint.sh: 4 x SLEEP(2) overlap in under 4 s, cap 2 lets 2 of 4 through and refuses 2, max_connections = 1 with one idle client refuses the call. 40 checks; with the bypass left on, the max_connections check fails. Part of #256 (RFC 0001 Phase 5). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 51 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Phase 5 items from #256: more than one I/O worker and the per-account session cap, plus
max_connections.Change
mcp_http.threads(read-only, default 4, range 1–64): the number of RouterIoComponentworker threads. Each worker serves one call at a time, since SQL runs synchronously on it. Router's HTTP server assigns connections to the workers in turn (Server::return_next_thread). The spike had one worker.mcp_http.max_sessions_per_account(read-only, default 4, range 1–1024): a per-account count of open endpoint sessions, kept under a mutex.ER_TOO_MANY_USER_CONNECTIONS(1203).max_user_connectionsdoesn't apply to command-service sessions (verified in fix(mcp-guard): guard sessions opened by components (RFC 0001 Phase 4, Q4) #252).max_connections: the sessions now setMYSQL_COMMAND_BYPASS_MAX_CONNECTIONS = false(26.10). Before, they counted towardmax_connectionsbut could exceed it, which is the command service's default. When the server is full, a call now fails with 1040.Tests
scripts/test-mcp-endpoint.shonmysql:26.10.0: 40 passed, 0 failed. New checks:SELECT SLEEP(2)calls all succeed, in under 4 s wall time (they overlap);max_connections = 1and one idle client, the call fails with 1040. It works again once the limit is restored;mcp.sessions_connectedis back to 0 afterwards.Built once with the bypass left
true: themax_connectionscheck fails. So the test covers the change.Docs: settings table, Phase 5 facts, CHANGELOG.
Independent of #257 and #258. All three touch
run_as(), so later merges get a merge from main.Part of #256.
🤖 Generated with Claude Code