Replies: 6 comments
-
Thanks for the kind words! ❤️ We could introduce a macro, We could add a switch/check box to the Params tab—"Include dashboard variables" or something—that would add the dashboard variables to the UI, but disable the fields. That way you could see what's actually being passed as well. WDYT? |
Beta Was this translation helpful? Give feedback.
-
The "include dashboard variables" check would definitely solve the issue in my use case. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
Thanks @AgentBignose for the kind words, and for the detailed feature request ❤️ I like the idea! Unfortunately, afaik plugins can't query the full set of values for a variables (only the currently selected ones), which would make this rather difficult to implement. I guess the reason why you can't use a top-level dashboard variable as is, is because you want to change it for each panel? |
Beta Was this translation helpful? Give feedback.
-
Hi @marcusolsson , thx for your instant reply!
Yes that limitation really is unfortunate.
Hm, so if I'd had a single query var but holding an array of the possible TAGNAMES returned by my meta-api and have this var selected in the dash it could work? I think today it's really important to have things dynamically connected. There is lots of potential for grafana.
Yes, Exactly |
Beta Was this translation helpful? Give feedback.
-
Yes, but I think not many data sources in Grafana would let you return a JSON array, and we'd have to somehow tell the JSON plugin to parse the value as an array. Another alternative would be to have a drop-down where you could select from the selected values in a variable. You could then create a Multi-value variable with "Include all" selected to achieve the same thing? Another challenge is how the plugin would know that TAGNAMES refer to a dashboard variable. In your example, you have a separate tab for this, but I'd like to integrate this in the key value component, so that it could be used with both params and headers. |
Beta Was this translation helpful? Give feedback.
-
Hello, to begin I must say thanks for your work: the plugin is exactly was I was looking for. Really, thank you 👍
Now a request, or maybe an hint, if this can be done already: I'd like to use, as mentioned in the subject, all the variables defined in the dashboard as QueryString parameters of a specific query to the JSON Datasource, without declaring all the var:$var, var2:$var2 verbose key:val pairing. Any way to do that or any interest by you in supporting that?
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions