You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Summary
Fixes format-selection precedence for ClickHouse 26.8+, where the X-ClickHouse-Format request header now takes priority over a SQL FORMAT clause (issue #3086). The PR moves the default format (RowBinaryWithNamesAndTypes) from being injected per-operation in Client.query() to a client-level default on ClientConfigProperties.INPUT_OUTPUT_FORMAT, so users can set format to null/empty to omit the header and let the query's FORMAT clause (or server default_format) take effect. It also adds a new Client.Builder.queryFormat(String) method, makes enum config parsing case-insensitive with trimming, skips null parsed values in parseConfigMap, null-guards the format header in HttpAPIClientHelper, and updates the docs/features.md compatibility contract, integration docs, examples, and client-v2/jdbc-v2 tests (jdbc-v2 changes are test-only).
User-facing format-selection behavior for both client-v2 and jdbc-v2 consumers (which format header is sent, and when SQL FORMAT clauses are honored)
Documentation compatibility contract (docs/features.md), integration docs, example project, and tests in client-v2 and jdbc-v2
Concerns
Medium rule: behavioral change in a hot-path module (client-v2) — format resolution moved from operation level to client config, changing when the X-ClickHouse-Format header is sent.
Medium rule: changed default of an existing setting — INPUT_OUTPUT_FORMAT previously had no config-level default; it now defaults to RowBinaryWithNamesAndTypes and is a new connection-property surface for jdbc-v2.
Scope wider than the fix: parseValue enum matching became case-insensitive/trimmed for all enum-typed settings, and parseConfigMap now silently drops null-parsed values — both affect config handling beyond the format setting.
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
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.
Summary
Closes: #3086
Checklist
Delete items not relevant to your PR: