-
Notifications
You must be signed in to change notification settings - Fork 19
enable parallel view processing for inserts #220
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
enable parallel view processing for inserts #220
Conversation
WalkthroughA new ClickHouse connection setting, Changes
Sequence Diagram(s)sequenceDiagram
participant App
participant ClickHouse
App->>ClickHouse: Connect with settings (including "parallel_view_processing": "1")
ClickHouse-->>App: Connection established
✨ Finishing Touches
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (1)
internal/storage/clickhouse.go (1)
103-107
:❓ Verification inconclusive
Add context and verify compatibility for the new setting
You’ve enabledparallel_view_processing = "1"
to allow view queries to execute parts in parallel. To ensure smooth rollout:
- Document why this setting is required, link to ClickHouse docs, and note the minimum CH server version (e.g., 22.6+) that supports it.
- Confirm that all environments (dev/test/prod) run a ClickHouse version which recognizes this setting; otherwise it may be ignored or rejected.
Please confirm server compatibility—e.g., via:
and add a comment or README entry referencing the setting’s support matrix.
🏁 Script executed:
clickhouse-client --query "SELECT version();"
Length of output: 155
Verify ClickHouse version compatibility
We attempted to runclickhouse-client --query "SELECT version();"
in this environment, but the binary isn’t available. Please manually confirm that all environments (dev/test/prod) are running a ClickHouse server version that supportsparallel_view_processing
(e.g., ≥22.6). Once confirmed, add or update documentation to:
- Explain why
parallel_view_processing = "1"
is required.- Link to the official ClickHouse docs on this setting.
- Note the minimum server version needed.
TL;DR
Enable parallel view processing in ClickHouse connection settings.
What changed?
Added the
parallel_view_processing
setting with a value of "1" to the ClickHouse connection settings in theconnectDB
function.How to test?
Why make this change?
Enabling parallel view processing allows ClickHouse to process views more efficiently by executing parts of view queries in parallel. This can significantly improve performance for complex queries that involve views, especially on systems with multiple CPU cores.
Summary by CodeRabbit