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
PublicDashboards: Orphaned public dashboard deletion script added #57917
Conversation
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.
Bulk deletion migrations are scary. This is a great Halloween PR 😱
Tested it out just be sure, and works as expected. LGTM 👍
Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/40004 |
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.
Let's hold off on this. Will discuss at standup
Discussion follow-up post standup. We did not previously delete public dashboards when deleting a dashboard so it is possible that instances have orphaned public dashboards. This migration deletes those. We are also merging (today) the ability for a user to delete dashboards from the audit table. Orphaned dashboards will be shown as well with the ability to delete them. @bergquist How do you feel about this destructive migration? |
This reverts commit 159c432.
Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/40234 |
This pull request was removed from the 9.3.0-beta1 milestone because 9.3.0-beta1 is currently being released. |
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.
Did we decide to go ahead with this? Can't remember, it was so long ago lol
I followed up directly with @bergquist and @grafana/hosted-grafana-team via slack. |
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.
Per discussion with @hairyhenderson: There is no way to run this same sql across instances in cloud that are archived. We do have an alternative to do this in the UI, however, it's straight forward, basically idempotent, and an edge case that is covered moving forward, so we'll run this one.
Drone build failed: https://drone.grafana.net/grafana/grafana-enterprise/42966 |
What is this feature?
PublicDashboards: When a dashboard was deleted, public dashboard was not also deleted. There was already a change to delete also public dashboards, but there can be remaining orphaned public dashboards before this chain deletion which can appear in Audit table.
This feature makes a deletion on public dashboard table, for those who don't have a dashboard.
Why do we need this feature?
Deletes orphaned public dashboards.
Which issue(s) does this PR fix?:
Fixes #478
Special notes for your reviewer: