Skip to content

Allow compression for ClickHouse clientΒ #9340

@Graphmaxer

Description

@Graphmaxer

Is your feature request related to a problem? Please describe.
When querying large datasets with a big LIMIT (like 50 000 for example), the time to process the query inside Cube is very slow compared to the same query directly run via ClickHouse CLI in SQL.

Simple SELECT with 50 000 rows on Cube (3.8s):
Image

Same query directly on ClickHouse (instant):
Image

Describe the solution you'd like
The compression option on ClickHouse JS client (https://clickhouse.com/docs/integrations/javascript#compression) can help with large data (https://clickhouse.com/docs/integrations/javascript#tips-for-performance-optimizations).

With compression enabled (1.1s):
Image

Describe alternatives you've considered
I have tried to add more CPU/RAM to the Cube API service, but the issue is still present.

Additional context
Compression cannot be enabled with read only https://clickhouse.com/docs/integrations/javascript#read-only-users

Metadata

Metadata

Assignees

No one assigned

    Labels

    backend:cliIssues relating to the CLI utilitydriver:clickhouseIssues related to the ClickHouse driver

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions