Releases: ClickHouse/clickhouse-java
Release v0.3.2-patch8
This is a patch release mainly for fixing below issues:
- fix issue with null in legacy JDBC driver json response deserializer - #879
- fix issue set String as Enum value in new JDBC driver - #883
- fix issue when deserializing array of DateTime with timezone - #886
Note: for exampleMap(String,Array(Nullable(DateTime64(3,'Asia/Shanghai')))) - fix key type when deserializing map objects - #887
- fix issue parsing Tuple with names - #889
In addition, more changes(mostly related to streaming) were merged from 0.3.3 branch along with some new features:
- TLS authentication support - #523
- support SimpleAggregateFunction data type
- initial support of experimental data type JSON/Object('JSON')
select tuple(1,[2,3], map('4', 5))::Tuple(Int32, Array(Int32), Map(LowCardinality(String), Int32)) select tuple(1,[2,3], map('4', 5))::Tuple(i1 Int32, a1 Array(Int32), m1 Map(LowCardinality(String), Int32))
If you're using Java client, please be aware of below changes which may or may not cause compiling errors:
- many methods changed to return ClickHouseInputStream/ClickHouseOutputStream instead of plain InputStream/OutputStream
- ClickHouseLZ4InputStream and ClickHouseLZ4OutputStream are removed
commits...
- [37d261b]: Use getSetting function to retrieve setting as suggested in #866 (Zhichun Wu) #869
- [772d304]: Add default rounding mode as suggested in #864 (Zhichun Wu) #869
- [30814bf]: switch to v0.3.3 (Zhichun Wu) #869
- [de92f70]: Fix broken links (Zhichun Wu)
- [7714fa8]: fixed issue with null in legacy driver's json response + test (debychkov) #879
- [8e32c3b]: Fix key type when deserializing map objects (Jean-Noel Delavalade) #887
- [ed47720]: Support Object/JSON and Tuple with names and types (Zhichun Wu) #890
- [096fcf2]: Rename root element (Zhichun Wu) #890
- [e86bd13]: Patch container before integration test (Zhichun Wu) #890
- [35fad2d]: Fix build break caused by server compatibility issue (Zhichun Wu) #890
- [72afe97]: Enhance data type handing and conversion between IPv4 and IPv6 (Zhichun Wu) #890
- [4b651f7]: Fix test failure (Zhichun Wu) #890
- [f782b77]: return string by default for enum column (Zhichun Wu) #890
- [5cd7e0b]: Update dependency, doc and version (Zhichun Wu) #890
- [c909574]: Clean up code and enhance enum types (Zhichun Wu) #890
- [8448caa]: Update benchmarks (Zhichun Wu) #890
- [4c5a101]: Merge stream changes from v0.3.3 branch along with TLS and exception handling improvement (Zhichun Wu) #890
- [822673d]: Upgrade gRPC client (Zhichun Wu) #890
- [67ff035]: Fix javadoc error on CI (Zhichun Wu) #890
- [2d3779c]: Add workaround for 21.3 / 21.8 (Zhichun Wu) #890
- [47af1ff]: stop testing grpc on 21.8 or early version (Zhichun Wu) #890
- [2d785c0]: Stop testing TLS client authentication (Zhichun Wu) #890
- [27dfc0c]: Skip default value test for gRPC (Zhichun Wu) #890
- [b1706dc]: Fix test failures on 21.3 and 21.8 (Zhichun Wu) #890
- [ffd81d7]: Enhance error handling and reduce temporary objects (Zhichun Wu) #890
- [795dd30]: Benchmark against 22.3 (Zhichun Wu) #890
- [14f856a]: Skip gRPC tests unless ClickHouse is 22.3+ (Zhichun Wu) #890
- [0e2b532]: Skip a few more tests on 21.3 (Zhichun Wu) #890
- [97ee2d1]: Update readme (Zhichun Wu) #899
- [753e67f]: add session_id connection property and expose more change events (Zhichun Wu) #899
Release v0.3.2-patch7
This is a patch release for fixing below issues in both Java client and JDBC driver.
- fix backward compatibility issue in legacy driver - #862
- fix rounding error when converting Float/Double value to BigDecimal - #864
- enable read-only support in JDBC driver - #866
In addition, there are a few more changes were merged from 0.3.3 branch:
ResultSet.unwrap()now supportsClickHouseRecord(current row) in addition toClickHouseResponse(whole results)ClickHouseColumnnow provides estimated byte length, which can be used in read/write optimization- synchronous methods
ClickHouseClient.executeAndWait()andMutation.sendAndWait()for ease of use
commits...
- [5143fe2]: added custom deserializer to legacy ClickHouseResponse (debychkov) #862
- [bfa5698]: Add rounding mode for irrational BigDecimal numbers (volodya-lombrozo) #864
- [2bd41ff]: remove empty spaces (volodya-lombrozo) #864
- [5e8e016]: Add test and dedup code (Zhichun Wu) #862
- [0b99f24]: Revert format changes (Zhichun Wu) #862
- [253cc7c]: Add tests and change RoundingMode to DOWN for consistency (Zhichun Wu) #864
- [48ee26e]: Enable read-only support (Zhichun Wu) #866
- [55b71cb]: Bump version (Zhichun Wu) #867
- [6977c17]: Merge a few more changes from 0.3.3 branch (Zhichun Wu) #867
Release v0.3.2-patch6
This is a patch release for fixing below issues in both Java client and JDBC driver.
- enhance Bool support - #848
- fix confusing error message metioned in #849
- fix issue of writing Date32 value in RowBinary format
- fix OffsetDateTime parsing error
- fix NumberFormatExcption when parsing primitive array with null value
- fix incorrect column type used in Connection.createArrayOf method
- enhance PreparedStatement by treating
insert into table(col1,col2,col3) values(?,?,?)asinsert into table(col1,col2,col3)
commits...
- [5e4354e]: fix links in README.md (XenoAmess) #852
- [877e20c]: Enhance Bool support (Zhichun Wu) #853
- [6cd6821]: Fix build break on JDK 8 (Zhichun Wu) #853
- [3a28431]: Fix test failure on CH older than 22.1 (Zhichun Wu) #853
- [b90c9c5]: Bump dependencies (Zhichun Wu) #854
- [46e976e]: Bump version (Zhichun Wu) #855
- [ec91d1f]: Fix issue of writing Date32 value (Zhichun Wu) #855
- [f4a2fb3]: Fix confusing error message in #849 (Zhichun Wu) #855
- [3558498]: Fix OffsetDateTime parsing error (Zhichun Wu) #855
- [1a53839]: Fix NumberFormatExcption when parsing primitive array with null value (Zhichun Wu) #855
- [09cd66e]: Treat "insert into table values(?,?)" as "insert into table" (Zhichun Wu) #855
- [046c3f2]: Correct behavior of Connection.createArrayOf (Zhichun Wu) #856
Release v0.3.2-patch5
This is a patch release primarily for fixing below issues in JDBC driver. You don't have to upgrade if you're using Java client.
continueBatchOnErrorwas ignored in Statement.executeBatch()- executeQuery() may return null
- PreparedStatement.executeUpdate() did not work for insert statement using input function
- Exception was swallowed in Statement.executeUpdate() - #836
In addition, exception handling is improved along with some minor changes:
- support largeMaxRows, largeUpdateCount and executeLargeBatch
- disable
execute(*),executeQuery(*),execute*Update(*), andaddBatch(*)methods in PreparedStatement to follow JDBC standard - throw BatchUpdateException instead of SQLException in execute*Batch method
- empty batch is no longer allowed - addBatch is a required before execute*Batch
- query in batch is not allowed, according to JDBC standard
- mixed use of addBatch and execute / executeQuery / execute*Update is not allowed
- ported some IO classes from 0.3.3 branch for slightly improved performance
commits...
- [7439cef]: Bump version (Zhichun Wu) #837
- [2782a3b]: Throw error in executeUpdate() and support continueBatchOnError in executeBatch() (Zhichun Wu) #837
- [ea49d7f]: Add notice for upgrading (Zhichun Wu)
- [6fdf02a]: Change max_result_rows from int to long (Zhichun Wu) #841
- [8ff5cdf]: Add reusable empty ClickHouseResponse which is stateless (Zhichun Wu) #841
- [ab09d64]: Enhance exception handling along with largeMaxRows and largeUpdateCount support (Zhichun Wu) #841
- [fd4b47f]: Port IO classes from 0.3.3 (Zhichun Wu) #841
- [105de13]: Validate JDK 11 HttpClient-based impementation as well (Zhichun Wu) #841
- [db4e219]: Call HttpURLConnection.disconnect when closing response, and avoid double buffering (Zhichun Wu) #841
Release v0.3.2-patch4
This is a patch release for fixing issues in both Java client and JDBC driver:
- Incorrect value may return when converting large UInt64 value from String to Long - #828
- Not able to create JDBC connection when database(defined in connection property or url) does not exist - #826
Note:createDatabaseIfNotExistconnection property was added as suggested in #605.
commits...
- [1b89743]: Bump versions (Zhichun Wu) #829
- [fd32335]: Fix issue #828 (Zhichun Wu) #829
- [8b6a969]: Benchmark after release (Zhichun Wu) #829
- [f8a79f3]: test jdbc driver using both http and grpc protocols (Zhichun Wu) #829
- [a747d43]: Abstract test cases and consider grpc when testing jdbc driver (Zhichun Wu) #829
- [ddc824c]: Remove database from context when initializing connection and add new connection property
createDatabaseIfNotExist(Zhichun Wu) #829 - [a17e4f9]: Fix build failures (Zhichun Wu) #829
- [3268c2e]: Update grpc spec (Zhichun Wu) #829
- [108d6ac]: Document new JDBC connection property (Zhichun Wu) #829
- [2f10655]: Disable grpc test on 21.3 and 21.8 (Zhichun Wu) #829
- [cd2dc12]: Convert string to primitive array (Zhichun Wu) #829
Release v0.3.2-patch3
This is a patch release primarily for fixing below issues in JDBC driver:
- Incorrect COLUMN_SIZE, DECIMAL_DIGITS, and CHAR_OCTET_LENGTH were returned from ClickHouseDatabaseMetaData.getColumns() - #807
- Failed to parse insert statement with CTE - #810
- PreparedStatement.setBytes() and ResultSet.getBytes() do not work
In addition, please be aware of below changes related to ClickHouseDataType:
- Enum is deprecated and it will be removed in 0.3.3 - it should be an alias of Enum8
- More aliases like
VARBINARYwere added
commits...
- [2631c0d]: Fix null DECIMAL_DIGITS and CHAR_OCTET_LENGTH (Zhichun Wu) #815
- [2949c8a]: Fix test failure (Zhichun Wu) #815
- [47bf6b0]: Consider CTE when parsing insert statement (Zhichun Wu) #817
- [c9ea0a1]: More data type aliases, return scale for number and datetime, and better binary string support (Zhichun Wu) #815
- [b11e807]: Improve binary data support (Zhichun Wu) #815
- [241feb3]: Use null binary value instead of empty byte array (Zhichun Wu) #815
- [671cd32]: Bump version to 0.3.2-patch3 (Zhichun Wu) #815
Release v0.3.2-patch2
This is a patch release for fixing issue of getting table meta data from ClickHouse server older than 21.6 - see #804 for details.
Java client does not have the issue, so you can continue to use 0.3.2.
Release v0.3.2-patch1
This is a patch release for fixing NullPointException in JDBC driver when getting null date/datetime values from ResultSet - see #797.
Java client does not have the issue, so you can continue to use 0.3.2.
commits...
- [0dccb76]: Fix NullPointerException (lin.chen) #797
- [48893a2]: Add test for nullable date and datetime values (Zhichun Wu) #798
- [be3a8ff]: Bump 3rd party dependencies (Zhichun Wu) #798
- [8bc91d0]: Bump version and dependencies (Zhichun Wu) #800
- [b2805fd]: Make grpc client less annonying and increase overall timeout by adding socket timeout (Zhichun Wu) #800
- [6f4b879]: Add examples (Zhichun Wu) #800
Release v0.3.2
Despite from the version number and unusually long release cycle, this is a complete re-write. This means it's not a drop-in replacement of previous versions, and it may surprise you in certain cases. However, it's highly recommended to start integrating the new JDBC driver and Java client, not only for more features but also better performance - please refer to #768 for details.
-
KNOWN ISSUES
- new driver
com.clickhouse.jdbc.ClickHouseDriverdoes not work with version before 20.7 java.io.IOException: HTTP/1.1 header parser received no byteswhen using JDK 11+ andhttp_connection_provideris set toHTTP_CLIENTRESOURCE_EXHAUSTED: Compressed gRPC message exceeds maximum sizewhen use gRPC - please increasemax_inbound_message_sizeselect 1 format JSONworks in http but not grpc, because grpc client is not aware of response format- gRPC is "slow" by default because it uses gzip instead of lz4 - see ClickHouse/ClickHouse#28671
- many connection properties are gone - please use
custom_http_paramsand maybecustom_http_headersinstead - NPE when query null Date/DateTime - see #797 (will be fixed in 0.3.2-patch1)
- new driver
-
NEW FEATURES
- Java client and JDBC driver are now in different modules
- Replaced data format from TabSeparated to RowBinary
- Support both HTTP and gRPC - Native/TCP will be available in next release
- Support more data types including Bool, Date32, Geo types, and mixed use of nested types(e.g. array of tuples)
- Enhanced pipeline for better performance and less memory footprints - still plenty of room to improve according to ranking here
- More JDBC APIs(especially those related to metadata) are implemented
- Better date time and time zone support
-
BUG FIXES
- stale connection validation to mitigate
failed to respondissue - parsing NaN and Inf/-Inf
- stale connection validation to mitigate
commits...
- [e6205b4]: Use jdk 11 to build (Zhichun Wu) #735
- [007d167]: Initial import of the new client (Zhichun Wu) #736
- [43dff6d]: Fix build break (Zhichun Wu) #736
- [9686cd4]: Discard known issues when testing against CH older than 21.9 (Zhichun Wu) #736
- [aea7d4b]: Fix maven build warnings (Zhichun Wu) #737
- [f66139a]: Remove groupId declaration for consistency (Zhichun Wu) #737
- [77e67bc]: Skip negative test of DateTime/DateTime32 on 21.3 (Zhichun Wu) #737
- [85c3bcf]: Only compares year and major version (Zhichun Wu) #737
- [7f505be]: Skip failed cases in certain releases (Zhichun Wu) #737
- [d5c72b0]: Limit timezone testing to JDBC driver (Zhichun Wu) #738
- [32ca307]: Add simple cache mechanism based on Caffeine and LinkedHashMap (Zhichun Wu) #739
- [19f0c9d]: Support maven-like version range (Zhichun Wu) #739
- [1eb0753]: Apply version range change and enhance DNS resolver (Zhichun Wu) #739
- [6015f67]: replace Jackson to Gson (Zhichun Wu) #740
- [7e3fc8f]: Remove slf4j dependency from JDBC driver (Zhichun Wu) #741
- [a8ac5b2]: Restore readUnsignedLeb128 method as requested in #710 (Zhichun Wu) #742
- [4f93201]: support credentials and protocol (Zhichun Wu) #742
- [cd32678]: Downgrade to JDK8 API (Zhichun Wu) #742
- [9b23915]: prepare jdbc refactoring (Zhichun Wu) #746
- [2bf54d8]: Bump 3rd party libs (Zhichun Wu) #746
- [d09d385]: Primitive array, serializable option, and shaded jars (Zhichun Wu) #747
- [dae6fdd]: ClickHouseRecord no long throws IOException and add its default implementation (Zhichun Wu) #747
- [6d18204]: Simplify response and error handling (Zhichun Wu) #747
- [675d382]: Enhance exception handling and expose stream response (Zhichun Wu) #747
- [c4b411b]: Drop for no usage and security reason (Zhichun Wu)
- [7f09be8]: Validate stale connection in HTTPClient pool. (Ryan Tu) #760
- [9afa1c4]: Add test cases for ValidateAfterInactivityMillis settings (Ryan Tu) #760
- [afbb426]: New JDBC driver along with improved Java client (Zhichun Wu) #747
- [8bd979b]: Fix build break (Zhichun Wu) #747
- [369ce06]: Fix test failure when using test container (Zhichun Wu) #747
- [331fffb]: Correct class file name (Zhichun Wu) #747
- [81cf79c]: Remove obsolete file (Zhichun Wu) #747
- [1b4b1d3]: Move parser to new package (Zhichun Wu) #747
- [32ba411]: Enable toolchain with multiple JDKs (Zhichun Wu) [#762](#7...
Release v0.3.2-test3
Commits
- [e6205b4]: Use jdk 11 to build (Zhichun Wu) #735
- [007d167]: Initial import of the new client (Zhichun Wu) #736
- [43dff6d]: Fix build break (Zhichun Wu) #736
- [9686cd4]: Discard known issues when testing against CH older than 21.9 (Zhichun Wu) #736
- [aea7d4b]: Fix maven build warnings (Zhichun Wu) #737
- [f66139a]: Remove groupId declaration for consistency (Zhichun Wu) #737
- [77e67bc]: Skip negative test of DateTime/DateTime32 on 21.3 (Zhichun Wu) #737
- [85c3bcf]: Only compares year and major version (Zhichun Wu) #737
- [7f505be]: Skip failed cases in certain releases (Zhichun Wu) #737
- [d5c72b0]: Limit timezone testing to JDBC driver (Zhichun Wu) #738
- [32ca307]: Add simple cache mechanism based on Caffeine and LinkedHashMap (Zhichun Wu) #739
- [19f0c9d]: Support maven-like version range (Zhichun Wu) #739
- [1eb0753]: Apply version range change and enhance DNS resolver (Zhichun Wu) #739
- [6015f67]: replace Jackson to Gson (Zhichun Wu) #740
- [7e3fc8f]: Remove slf4j dependency from JDBC driver (Zhichun Wu) #741
- [a8ac5b2]: Restore readUnsignedLeb128 method as requested in #710 (Zhichun Wu) #742
- [4f93201]: support credentials and protocol (Zhichun Wu) #742
- [cd32678]: Downgrade to JDK8 API (Zhichun Wu) #742
- [9b23915]: prepare jdbc refactoring (Zhichun Wu) #746
- [2bf54d8]: Bump 3rd party libs (Zhichun Wu) #746
- [d09d385]: Primitive array, serializable option, and shaded jars (Zhichun Wu) #747
- [dae6fdd]: ClickHouseRecord no long throws IOException and add its default implementation (Zhichun Wu) #747
- [6d18204]: Simplify response and error handling (Zhichun Wu) #747
- [675d382]: Enhance exception handling and expose stream response (Zhichun Wu) #747
- [c4b411b]: Drop for no usage and security reason (Zhichun Wu)
- [7f09be8]: Validate stale connection in HTTPClient pool. (Ryan Tu) #760
- [9afa1c4]: Add test cases for ValidateAfterInactivityMillis settings (Ryan Tu) #760
- [afbb426]: New JDBC driver along with improved Java client (Zhichun Wu) #747
- [8bd979b]: Fix build break (Zhichun Wu) #747
- [369ce06]: Fix test failure when using test container (Zhichun Wu) #747
- [331fffb]: Correct class file name (Zhichun Wu) #747
- [81cf79c]: Remove obsolete file (Zhichun Wu) #747
- [1b4b1d3]: Move parser to new package (Zhichun Wu) #747
- [32ba411]: Enable toolchain with multiple JDKs (Zhichun Wu) #762
- [b731608]: Fix substitution issue (Zhichun Wu) #762
- [d83f10b]: Add JDK distribution (Zhichun Wu) #762
- [659728e]: Remove checkstyle step (Zhichun Wu) #763
- [cdbab02]: Basic benchmark against new JDBC driver (Zhichun Wu) #763
- [1ee8668]: Introduce ClickHouseInputStream for tiny reads (Zhichun Wu) #763
- [395bc03]: Update benchmarks to cover more data types (Zhichun Wu) #763
- [d11fac0]: Fix JDK 8 build failure (Zhichun Wu) #764
- [66ba8d0]: Simplify build script (Zhichun Wu) #764
- [ce528f1]: Remove JAXB dependency (Zhichun Wu) #764
- [433afda]: Close initial connection when needed (Zhichun Wu) #764
- [05e89d8]: Benchmark both http and grpc implementations (Zhichun Wu) #764
- [[1b0714a](https://github...