-
Notifications
You must be signed in to change notification settings - Fork 259
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Java Client] Reorganized documentation #2646
Conversation
- `http://(https://[email protected]:443` | ||
- `tcp://localhost?!auto_discovery#experimental),(grpc://localhost#experimental)?failover=3#test` | ||
All settings are defined by instance methods (a.k.a configuration methods) that make scope and context of each value clear. | ||
Major configuration parameters are defined in one scope (client or operation) and do not override each other. Handling |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't operation
-level parameter override a parameter defined on the instance level?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only in some cases, for example timeouts.
We do not guarantee to make all settings overridable because in certain cases it would mean creating another client instance. For example, we may not turn-off connection pool for an operation.
The library provides all need to send requests and parse responses. | ||
|
||
First Java client was developed far back in 2015. We have refactored it in 2024 and have introduced a new component - `client-v2`. New implementation has | ||
new improved API, new underlying implementation and many other improvements. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
improvements
maybe we can link to a section of improvements if there is already one if not to create one
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've re-phrased.
# Java Client (V2) | ||
|
||
Implementation of a new API. It uses Apache Http Client to communicate with ClickHouse server. We have selected this http client because it has many built-in features and | ||
has proven itself in old client implementation. We are planning to support other http client libraries. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would explain why we did it (from an API simplicity perspective)
Why we are saying We are planning to support other http client libraries
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've reworked this section for both clients. It actually should explain what is this library.
Major configuration parameters are defined in one scope (client or operation) and do not override each other. Handling | ||
configuration overriding across is a very hard task so we doing our best to keep it simple. | ||
|
||
This section describes only client wide settings. Each operation may have own and will be listed in the their sections. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The section doesn't describe any settings. Should we remove this part?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've gave a reference to builder class for docs. Will fill this section a bit later.
|
||
## Supported data types | ||
|
||
JDBC Driver supports same data formats as client library does. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
JDBC Driver supports same data formats as client library does. | |
JDBC Driver supports same data formats as [the client library does](/docs/en/integrations/java). |
options.put("custom_http_headers", "X-ClickHouse-Quota=test, X-ClickHouse-Test=test"); | ||
``` | ||
|
||
## JDBC Driver |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be on the JDBC driver page
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
left a couple of minor nits. Let's
Summary