Skip to content

Expose X-ClickHouse-Server-Display-Name header via client-v2 API#2744

Merged
chernser merged 2 commits intoClickHouse:mainfrom
BigDataBoutique:expose-server-display-name-header
Feb 14, 2026
Merged

Expose X-ClickHouse-Server-Display-Name header via client-v2 API#2744
chernser merged 2 commits intoClickHouse:mainfrom
BigDataBoutique:expose-server-display-name-header

Conversation

@synhershko
Copy link
Contributor

@synhershko synhershko commented Feb 13, 2026

Extract the server display name from HTTP response headers and surface it through OperationMetrics, QueryResponse, InsertResponse, and CommandResponse, following the existing queryId pattern.


Note

Low Risk
Additive API surface that only reads and exposes a small, whitelisted set of response headers; minimal impact on request/response flow aside from extra header collection.

Overview
Client-v2 now captures a whitelisted set of ClickHouse HTTP response headers and attaches them to operation results.

Client passes collected headers into QueryResponse and InsertResponse, while QueryResponse, InsertResponse, and CommandResponse expose getServerDisplayName() (from X-ClickHouse-Server-Display-Name) plus getResponseHeaders() for the full collected map. HttpAPIClientHelper adds collectResponseHeaders() with a fixed whitelist to avoid exposing arbitrary headers.

Written by Cursor Bugbot for commit 8932875. This will update automatically on new commits. Configure here.

Extract the server display name from HTTP response headers and surface
it through OperationMetrics, QueryResponse, InsertResponse, and
CommandResponse, following the existing queryId pattern.

Signed-off-by: Itamar Syn-Hershko <itamar@bigdataboutique.com>
@CLAassistant
Copy link

CLAassistant commented Feb 13, 2026

CLA assistant check
All committers have signed the CLA.

@chernser
Copy link
Contributor

Good day, @synhershko !
Thank you for the contribution!
Please see my comment.

Thanks!

@synhershko
Copy link
Contributor Author

@chernser updated

@chernser chernser merged commit a0cea8c into ClickHouse:main Feb 14, 2026
18 of 21 checks passed
@chernser
Copy link
Contributor

Thank you @synhershko !

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.

3 participants