ClickHouse / ClickHouse/clickhouse-java

Can users set a fully custom User-Agent that completely replaces the default one, without appending the driver version?

オープン
#2,935 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る
area:general client-api-v2 enhancement
主要言語
Java
スター
1.6k
フォーク
636
平均マージ
2日 23時間
マージ済み PR(30日)
29

説明

### Use case
Security/compliance policies in some organizations require hiding internal client version information from server logs. Currently there is no way to do this from the client side.

### Describe the solution you'd like
Allow setting a fully custom User-Agent that completely replaces the default one, without appending the driver version.

### Describe the alternatives you've considered
When using the ClickHouse client to send requests to server, the User-Agent header always includes the driver version:User-Agent: ClickHouse-JavaClient/0.6.5 (OpenJDK 64-Bit Server VM/BiSheng_JDK_Enterprise_205.2.0.110.B001; Apache-HttpClient/5.3.4)

Using client_name can only prepend a custom prefix, but the driver version suffix is always appended at the end and cannot be removed.

### Additional context

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

まず、Java クライアントが User-Agent ヘッダーをどのように構築し、client_name がどのように適用されるかを追跡します。既存のクライアントリクエストのテストを確認し、その後、完全にカスタムされた値によってデフォルトのヘッダーが置き換えられ、ドライバーのバージョンが追加されないことを検証します。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
java
領域
api
issue の種類
機能追加
難易度
3/5
見積もり時間
1〜2日
活発さ
活発
明瞭さ
おおむね明確
初心者へのやさしさ
68/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。