Releases: patrick-zippenfenig/ClickHouseNIO
v1.4.2
1.4.1 Fix DateTime with TimeZone
1.4.0 Additional datatypes
What's Changed
- Support for more ClickHouse-Types by @planetMDX in #8
New Contributors
- @planetMDX made their first contribution in #8
Full Changelog: 1.3.0...1.4.0
1.3.0 Nullable
This feature release adds support for Nullable datatype
1.2.0 Timeouts
This release adds timeouts to make ClickHouseNIO more reliable in production environments.
While running ClickHouseNIO we discovered various edge cases where a connection could get stuck. These events are infrequent (once every 2 weeks), but result in annoying deadlocks.
Because networks unreliable by nature, ClickHouseNIO uses different timeouts to prevent potential deadlocks while waiting for a server response. All timeouts can be controlled via ClickHouseConfiguration
and use default values as shown below:
let config = try ClickHouseConfiguration(
hostname: "localhost",
...,
connectTimeout: .seconds(10),
readTimeout: .seconds(90),
queryTimeout: .seconds(600))
,
All timeouts will close the connection. Different timeouts trigger different exceptions:
connectTimeout
will throwNIO.ChannelError.connectTimeout(TimeAmount)
if the connection to the ClickHouse server cannot be establised after this period of time.readTimeout
: If a query is running, and the ClickHouseNIO client does not receive any network package, the conncection is closed and throwsClickHouseError.readTimeout
. This can happen, if the network connection is interrupted while waiting for a response. Usually, even while waiting for a query result, packages are exchanged very frequently.queryTimeout
is the total time after a query will be terminated and the connection is closed. Because ClickHouseNIO is also capable of queueing queries, this includes the time in the queue as well. On a very busy server, a long waiting time starts to close connections. If a connection is closed, all queries in the queue will return a failed future with the exceptionClickHouseError.queryTimeout
.
Timeouts can also be specified for a single query with connection.command(sql: sql, timeout: .seconds(30))
, but keep in mind that this also includes queue time.
1.1.2 Fix insert + select statements
Fixed a bug with the combination of insert & select statements like INSERT INTO db.table SELECT * FROM db2.table2
which triggered an assertion on non production builds
1.1.1 UUID coding bugfix
ixed:
- Bug #2 ClickHouse uses little endian encoding for UUIDs
1.1.0 TLS encryption support
TLS encrypted connections are now supported!
For TLS encrypted connections to the ClickHouse server, a tlsConfiguration
attribute can be set in the configuration. Usually port 9440 is used. certificateVerification: .none
disables certificate verification for self signed certificates. TLS connections use BoringSSL with SwiftNIO SSL.
let tls = TLSConfiguration.forClient(certificateVerification: .none)
let config = try ClickHouseConfiguration(
hostname: "localhost",
port: 9440,
user: "default",
password: "admin",
database: "default",
tlsConfiguration: tls)
1.0.1 ClickHouse server 20.x bugfix
Fix a small compatibility issue with ClickHouse server 20.x. For DROP TABLE statements a progress message is now send which was unexpected for this library.
See 789deba
1.0.0 First release
First version declared stable. Before it was in use at meteoblue for a while.