#support

Clickhouse Query Timeout in SigNoz Dashboard

TLDR Daniel experienced query timeouts in SigNoz dashboard. vishal-signoz confirmed it's a non-configurable 60s limit, but created a GitHub issue for adding the feature.

Powered by Struct AI

2

Apr 17, 2023 (5 months ago)
Daniel
Photo of md5-3076442c4997c13ee86556ecd18af2a8
Daniel
11:50 AM
Hi guys, I was wondering if this is a signoz issue or a clickhouse related issue. When I run clickhouse queries in the signoz dashboard editor, it always times out after 1 minute (and thus fails, queries faster than 1 minute do not fail). So is this something that signoz does not support? Or is this a clickhouse setting that I need to change? Any help would be greatly appreciated.
Ankit
Photo of md5-dbe7088320fe1d922707613e02f3420d
Ankit
11:59 AM
I think this is a clickhouse setting we enabled. Do you really need your queries to be running for more than 1 min? cc vishal-signoz
Daniel
Photo of md5-3076442c4997c13ee86556ecd18af2a8
Daniel
12:01 PM
Yes, we have a lot of data we are querying over. Is this a setting I could configure?
Ankit
Photo of md5-dbe7088320fe1d922707613e02f3420d
Ankit
12:10 PM
> Is this a setting I could configure?
I will let vishal-signoz reply on this.

> we have a lot of data we are querying over.
Is this a standard APM query or some other use case? Can you share a sample query (in simple English or SQL)? We might have ways to make it performant.
Daniel
Photo of md5-3076442c4997c13ee86556ecd18af2a8
Daniel
12:19 PM
SELECT quantile(0.99)(durationNano) as p99,
name,
toDateTime(toStartOfMinute(timestamp)) AS ts
FROM
()
WHERE( timestamp >= start_t
AND timestamp <= end_t
GROUP BY name,ts
ORDER BY p99 DESC

this is the basic query, it contains some more filtering to make it specific for a cluster and remove some unwanted data
vishal-signoz
Photo of md5-f936d3e5743d23344d6c60813189716f
vishal-signoz
12:28 PM
Daniel We have set default query timeout to 60s: https://github.com/SigNoz/signoz/blob/0bc44c6fd986ecde0513a153dd37a5baf4a7b339/pkg/query-service/constants/constants.go#L100
Currently it’s not configurable.
Created an issue to allow it to be configurable via env variable, Track here: https://github.com/SigNoz/signoz/issues/2582
Daniel
Photo of md5-3076442c4997c13ee86556ecd18af2a8
Daniel
12:30 PM
Thanks for the help! I'll keep an eye on the progress.

1

Ankit
Photo of md5-dbe7088320fe1d922707613e02f3420d
Ankit
12:34 PM
> this is the basic query, it contains some more filtering to make it specific for a cluster and remove some unwanted data
do you have serviceName in the filters? The query will be faster with ServiceName.
Daniel
Photo of md5-3076442c4997c13ee86556ecd18af2a8
Daniel
12:34 PM
yeah i do

1