Skip to content

clickhouse datasource is not respecting dataproxy config row_limit #1134

@andrejshapal

Description

@andrejshapal

What happened:
Hello,
There is a config in grafana:
https://grafana.com/docs/grafana/latest/setup-grafana/configure-grafana/#row_limit

row_limit - Limits the number of rows that Grafana will process from SQL (relational) data sources. Default is 1000000.

This prevents Grafana from being killed in case someone did not provide explicit LIMIT in query.

In postgres datasource it looks like this:

Image

While in clicklhouse datasource it does not respect the parameter:

Image

What you expected to happen:
clickhouse datasource would fail to query more than 3000 rows

How to reproduce it (as minimally and precisely as possible):

Set:

   dataproxy:
      logging: "true"
      timeout: "1200"
      row_limit: "3000"

Then make a query with LIMIT 3001 and see the result.

Environment:

  • Grafana version: Grafana v11.2.2 (dbf571744d)
  • Plugin version: v4.6.0
  • OS Grafana is installed on: linux
  • User OS & Browser: MacOs Chrome

Metadata

Metadata

Assignees

No fields configured for Enhancement.

Projects

Status

Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions