Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for repeat options #129

Merged
merged 1 commit into from
Oct 31, 2022

Conversation

wonderino
Copy link
Contributor

@wonderino wonderino commented Oct 25, 2022

When repeat a panel, grafana-druid query does not split multiple variables.

For example, in the first SQL panel of Grafadruid Wikipedia Sample dashboard, I selected multiple cities as variables and chose the variable in Repeat by variable under Repeat options. Panels were automatically repeated, but the dataset did not.

Screen Shot 2022-10-25 at 8 55 42 AM

Screen Shot 2022-10-25 at 8 54 25 AM

I found that scopedVars is used when repeat a panel or row, it is passed to templateSrv replace method as local overrides. So I add scopedVars as arguments in DruidDataSource.applyTemplateVariables method and pass it to the replace method.

Screen Shot 2022-10-25 at 9 58 38 AM

@wonderino wonderino changed the title Add support for repeat a panel Support for repeat options Oct 25, 2022
@jbguerraz
Copy link
Contributor

LGTM! Thank you @wonderino 👍

@jbguerraz jbguerraz merged commit 5e95a26 into grafadruid:master Oct 31, 2022
@m-ghazanfar
Copy link
Contributor

Thanks @wonderino !
How do I make this available in the plugin which I download via grafana? I am assuming that we have to release this? Is there a process to that? I'll be happy to help out.

@jbguerraz
Copy link
Contributor

Hello @Ghazanfar-CFLT,

Yep, we need to release to get it available on grafana.com.
I'll try to prepare a release soon (like in next days).

@ghost
Copy link

ghost commented Jan 12, 2023

Thanks @jbguerraz ! That will be super helpful!

@jbguerraz
Copy link
Contributor

@MohammadGhazanfar I'll release right after #133 fix

@eastcirclek
Copy link

@jbguerraz

I've waited for this feature to be officially available. This is largely because I don't know how to build and install it by myself 😅

@jbguerraz
Copy link
Contributor

jbguerraz commented Jan 24, 2023

@wonderino @MohammadGhazanfar @eastcirclek

Released!

image

Now have to wait for Grafana.com to review & publish it, meanwhile:

https://github.com/grafadruid/druid-grafana/releases/tag/v1.4.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants