cube-js / cube

📊 Cube — Universal semantic layer platform for AI, BI, spreadsheets, and embedded analytics
https://cube.dev
Other
17.96k stars 1.78k forks source link

Socket hang up while trying to connect with Clickhouse after updating cube to v.0.36.0 or higher #8942

Closed MarlousKottenhagen closed 1 day ago

MarlousKottenhagen commented 1 week ago

Describe the bug After updating cubejs to v0.36.0 or higher we are experiencing socket hang up errors while trying to connect to clickhouse.

These errors occur while we query clickhouse on a large dataset ( > 3 million rows). When using cube 0.35.81 or lower the same query does not give us any issues.

We are able to reproduce the issue on our kubernetes cluster and locally using docker containers.

Version: cubejs: v0.36.0 and higher clickhouse

Additional context We tried updating both cubejs and clickhouse to their latest version.

Mhs-220 commented 1 week ago

We also faced the same issue. On a related note, we have another error next to socket: hang up which is also new: Error: Code: 373. DB::Exception: Session 339a700f-2005-47e2-9ad8-752a401ddb6f is locked by a concurrent client. (SESSION_IS_LOCKED) (version 24.8.1.10338 (official build))

igorlukanin commented 1 week ago

@Mhs-220 Is this the same issue? https://github.com/cube-js/cube/issues/7906

@MarlousKottenhagen I feel like we need to wait for this PR to be merged and released as it might drastically improve how Cube works with ClickHouse: https://github.com/cube-js/cube/pull/8928

Mhs-220 commented 1 week ago

Yes, @igorlukanin it's the same. But, interestingly, this happened after our cube cloud was updated to v1; before that, we didn't have this issue.

Thanks a lot, we will wait for the PR to be merged and test it again.

MarlousKottenhagen commented 1 week ago

@igorlukanin Thanks for the answer, we will also wait for the PR to be merged and test it again!

mcheshkov commented 2 days ago

I've just merged ClickHouse client upgrade in #8928, next release should have those changes included. I'll ping again when release is ready.

mcheshkov commented 1 day ago

v1.1.7 was just released, it's already available on Docker Hub, soon will be on Cloud.

MarlousKottenhagen commented 1 day ago

@mcheshkov We tested it locally and there the issues are gone 😄. Next week we will release it on our kubernetes cluster and test it there!

mcheshkov commented 1 day ago

@Mhs-220 Could you test it as well?

Mhs-220 commented 1 day ago

@mcheshkov I can confirm that we don't have this problem anymore as well. Thanks a lot

mcheshkov commented 1 day ago

Great news!