-
Notifications
You must be signed in to change notification settings - Fork 227
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
Migrate Reports to OpenAPI #1228
Conversation
In order to lower resource usage and have a faster runtime, PRs will not run Cloud tests automatically. |
uid := d.Get("dashboard_uid").(string) | ||
if uid == "" { | ||
// It triggers the old way to generate reports | ||
report.DashboardID = id |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We aren't able to retrieve dashboards by id anymore.
We need to set it in the deprecated dashboard_id
to make it works.
@@ -235,7 +235,8 @@ func deleteAlertRuleGroup(ctx context.Context, data *schema.ResourceData, meta i | |||
group := resp.Payload | |||
|
|||
for _, r := range group.Rules { | |||
_, err := client.Provisioning.DeleteAlertRule(r.UID) | |||
params := provisioning.DeleteAlertRuleParams{UID: r.UID} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you rebase, you can get rid of this change and the go mod update!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah! I saw that in your PR 😂
a75c8f2
to
abc2ded
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!
It migrates Reports to OpenAPI.
Depends of: grafana/grafana-openapi-client-go#49