Deprecations
- Following components will be deprecated and archived in next release:
- clickhouse-cli-client
- clickhouse-grpc-client
- No more builds for non-lts Java versions - no more Java 9 release builds.
- Lowest supported Java version will be 11.
- Java 11 support will be ended before the end of 2023.
- It is recommended to use Java 21.
Important Changes
- [Client-V1] Fix for handling DateTime without timezone when
session_timezoneis set. Now server timezone
is parsed from server response when present (#1464)
New Features
- [Client-V1/Apache HTTP] More configuration parameters for connection management. Useful for tuning performance.
(#1771)- com.clickhouse.client.config.ClickHouseClientOption#CONNECTION_TTL - to configure connection time-to-live
- com.clickhouse.client.http.config.ClickHouseHttpOption#KEEP_ALIVE_TIMEOUT - to configure keep-alive timeout
- com.clickhouse.client.http.config.ClickHouseHttpOption#CONNECTION_REUSE_STRATEGY - defines how connection pool behaves.
IfFIFOis selected then connections are reused in the order they were created. It results in even distribution of connections.
IfLIFOis selected then connections are reused as soon they are returned to the pool.
Note: only forAPACHE_HTTP_CLIENTconnection provider. - Additionally switched to using LAX connection pool for Apache Connection Manager to improve performance
for concurrent requests.
- [Client-V2] Connection pool configuration #1766
- com.clickhouse.client.api.Client.Builder.setConnectionRequestTimeout - to configure connection request timeout.
Important when there are no connections available in the pool to fail fast. - com.clickhouse.client.api.Client.Builder.setMaxConnections - configures how soft limit of connections per host.
Note: Total number of connections is unlimited because in most cases there is one host. - com.clickhouse.client.api.Client.Builder.setConnectionTTL - to limit connection live ignoring keep-alive from server.
- com.clickhouse.client.api.Client.Builder.setConnectionReuseStrategy - to configure how connections are used.
Select FIFO to reuse connections evenly or LIFO (default) to reuse the most recently active connections.
- com.clickhouse.client.api.Client.Builder.setConnectionRequestTimeout - to configure connection request timeout.
- [Client-V2] All operations are now executed in calling thread to avoid extra threads creation.
Async operations can be enabled bycom.clickhouse.client.api.Client.Builder.useAsyncRequests(#1767) - [Client-V2] Content and HTTP native compression is supported now Currently only LZ4 is available. (#1761)
- [Client-V2] HTTPS support added. Required to communicate with ClickHouse Cloud Services.
Client certificates are supported, too. (#1753) - [Client-V2] Added support for HTTP proxy (#1748)
Documentation
- [Client-V2] Spring Demo Service as usage example (#1765)
- [Client-V2] Examples for using text based formats (#1752)