Hello there. Not sure where to raise help requests...
# openobserve
j
Hello there. Not sure where to raise help requests but I'm having a bit of difficulty with what feels like it should be a fairly straightforward dashboard pane. I want to to track the min of of deployments_available from kube state metrics, and have that broken down by namespace / deployment name pairs. This will be filtered by multi-selects for those labels and others. However, I can't seem to get this working with the SQL interface (at least via the query builder) as I can only add one of namespace or deployment name to the breakdown fields. And I can't get it working in the promql interface either, because promql label matches don't seem to expand multi-selects in any reasonable way. Am I missing something? Unfortunately I can't open Slack on my work computer to easily copy-paste things over, but I can provide further information if requested.
s
@Subhradeep Chakraborty can you help here
a
@James Turley for sql query, we do not support multiple breakdown fields as of now. for promql, here is how you can group by multiple fields.
j
@Abhay Padamani Thanks, but the problem on the promql side is that I can't seem to filter by multi-select variables - if I select multiple namespaces in my variable, this isn't expanded in any meaningful way to the promql label matchers. (I'm not completely sure how you would expand them - maybe to a big regex match like
(value1|value2|value3)
) but in any case it doesn't work yet.
a
can you share example query?
image.png
j
Oh, that looks very promising
a
Copy code
k8s_node_cpu_usage{k8s_cluster=~"${k8s_cluster:pipe}"}
will be replaced like this:
Copy code
k8s_node_cpu_usage{k8s_cluster=~"ap1cloud|common-dev"}
j
yes, that did the trick - thank you!