-
Notifications
You must be signed in to change notification settings - Fork 256
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
base: main
Are you sure you want to change the base?
Conversation
|
||
### Installation | ||
*Note*: Client-V2 is currently in the phase of active development and we are still working on it. |
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.
Im not sure what it means for the end user: that the v2 is not stable?
- `http://(https://explorer@play.clickhouse.com: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?
``` | ||
|
||
### Supported data types | ||
`Client` is `AutoCloseable` and should be closed when not needed anymore. |
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.
It's quite an important change. Should we move above the code snippet?
|
||
```java | ||
// Important step (done once) - register class to pre-compile object serializer according to the table schema. | ||
client.register(ArticleViewEvent.class, client.getTableSchema(TABLE_NAME)); |
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.
Can we add a link to a complete example?
``` | ||
|
||
Connect to a single node: | ||
If data is already in the format that ClickHouse accepts, then: |
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.
If data is already in the format that ClickHouse accepts, then: | |
If data is already in [the format that ClickHouse accepts](/docs/en/interfaces/formats), then: |
|
||
### Examples | ||
|
||
- Example code is available in [repo](https://github.com/ClickHouse/clickhouse-java/tree/main/examples/client-v2) |
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.
Adding a link with examples to each section (insert, query, etc.) would improve UX
- Example code is available in [repo](https://github.com/ClickHouse/clickhouse-java/tree/main/examples/client-v2) | ||
- Reference Spring Service [implementation](https://github.com/ClickHouse/clickhouse-java/tree/main/examples/demo-service) | ||
|
||
## Client-V1 |
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'd consider spitting the docs into different pages. A quick search for a term (eg, query
) might land a reader on a wrong version.
### Features | ||
#### Compression | ||
|
||
The client will by default use LZ4 compression, which requires this dependency: |
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.
If it's relevant for both clients, I see no problem in duplicating the information. especially if we split them into separate pages
``` | ||
|
||
### Compression | ||
### Query API |
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 expand the section with more specific examples: create a table, select, drop, etc. It can be done in a follow-up
Summary
Checklist