This message was deleted.
# troubleshooting
s
This message was deleted.
k
Are you using the prometheus metrics emitter? You should be able to use the metric
query/time
to get max/min/avg query times. Docs: https://druid.apache.org/docs/latest/operations/metrics.html#query-metrics
u
@kfaraz yes i am using query/time metric but confused how to use query_time_bucket to get max time
l
query/time
value is histogram type, so the wholepoint is to use for a heatmap type chart or to get quantiles from it. As the data is bucketized, you can’t get a min/max value out it. For quantiles use:
Copy code
histogram_quantile(0.5, sum(rate(query_time_bucket{druid_service="druid/broker"}[$__interval])) by (le)) 
histogram_quantile(0.95, sum(rate(query_time_bucket{druid_service="druid/broker"}[$__interval])) by (le))
For a heatmap use something like:
Copy code
sum by(le) (increase(query_time_bucket{druid_service="druid/broker"}[$__interval]))
with the heatmap view you can see what’s the window range for most your queries and even their max buckets. So I can tell I have very few awful queries in the 2-5 min range, but they are super rare. And even during the highest usage most my queries where < 100 ms
u
@Luiz Augusto Thanks for help
you can't get a min/max value
yes… its bucket so i cant get min max value got it