8000 Fixed config override not playing nicely with pool executors by andrei-katkov · Pull Request #191 · ClickHouse/mcp-clickhouse · GitHub
[go: up one dir, main page]

Skip to content

Fixed config override not playing nicely with pool executors - #191

Closed
andrei-katkov wants to merge 1 commit into
ClickHouse:mainfrom
andrei-katkov:config-override-fix
Closed

andrei-katkov wants to merge 1 commit into
ClickHouse:mainfrom
andrei-katkov:config-override-fix

Conversation

@andrei-katkov
Copy link
Copy Markdown
Contributor

Fixes request-scoped ClickHouse client config overrides getting lost when run_query executes in QUERY_EXECUTOR.

The server now captures FastMCP context state before the thread-pool handoff, deep-copies valid clickhouse_client_config_overrides, and passes them explicitly into the worker path. This preserves per-request settings.role for shared long-lived MCP server usage without relying on contextvars inside executor threads.

@joe-clickhouse
Copy link
Copy Markdown
Collaborator

Superseded by #221

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

0