Skip to content

Conversation

@Cheppali-Reddy
Copy link
Contributor

Allows to share same cookie store among http clients of same database. This feature allows users to use AWS ALB sticky sessions.

With the help of sticky sessions, we can direct all the queries from a given client to same CH node. We can achieve read your writes consistency at each client level (Client will always see the writes it made as we are hitting the same CH node - assuming other CH properties are appropriately configured).

@github-actions
Copy link

Benchmark                           (client)  (statement)   Mode  Cnt       Score       Error  Units
Basic.insertOneRandomNumber  clickhouse-jdbc       normal  thrpt   20  583011.711 ± 37844.430  ops/s
Basic.insertOneRandomNumber  clickhouse-jdbc     prepared  thrpt   20     259.039 ±    28.897  ops/s
Basic.selectOneRandomNumber  clickhouse-jdbc       normal  thrpt   20     962.817 ±    67.517  ops/s
Basic.selectOneRandomNumber  clickhouse-jdbc     prepared  thrpt   20     917.714 ±    88.755  ops/s

@zhicwu zhicwu changed the base branch from master to develop April 15, 2021 23:16
@zhicwu
Copy link
Contributor

zhicwu commented Apr 15, 2021

Thanks for the pull request @Cheppali-Reddy. Both client_name and session_id options can be used for routing, but it seems cookie is more user-friendly. Overall I'm good for the PR, and I'll merge over the weekend(hopefully after fixing the build break).

@github-actions
Copy link

🟢 verify using JDK [8, timezone=America/Los_Angeles] and ClickHouse [21.3, timezone=Asia/Chongqing]: success

@zhicwu zhicwu merged commit 46c8f47 into ClickHouse:develop Apr 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants