-
Notifications
You must be signed in to change notification settings - Fork 12.2k
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
version cleanup fails on old databases with many entries #11278
Comments
It sounds like the version cleanup job needs a limit on how many old versions it'll try to delete in one hit |
Yeap. I suggest we change how I think the select statement could be made into a When it comes to deleting I think we should delete ranges instead of per id.
Deleting ranges of rows is much more performant than deleting by id |
* grafana/master: (30 commits) changelog: adds note about closing grafana#11278 docs: spelling docs: add intro paragraph to provisioning page Cleanup CircleCI V2 Conversion changelog: notes for grafana#1271 and grafana#2740 graph: minor fixes to y-axes alignment feature added save icon to save buttons removed trash can icon from save buttons Return actual user ID in UserProfileDTO dashboard version cleanup: more tests and refactor minor refactor of dashboard version cleanup refactor: dashboard version cleanup limit number of rows deleted by dashboard version cleanup fix dashboard version cleanup on large datasets Allocated to a separate alignment block. Replaced the attribute of the second axis by the attribute of the axes. Fixed unit test. Changed the way this feature was activated. And changed tolltip. Added validation of input parameters. Resolved conflict Corrected work for graphs created before this feature. ...
What Grafana version are you using?
5.0.1
What datasource are you using?
Aurora5.6 on r4.larges
What OS are you running grafana on?
Amazon Linux
What did you do?
Upgraded
What was the expected result?
Version trim works
What happened instead?
t=2018-03-16T15:44:34+0000 lvl=eror msg="Failed to delete expired dashboard versions" logger=cleanup error="Error 1390: Prepared statement contains too many placeholders"
A couple of notes:
As a user of grafana for a long time we had a pre-existing system which was not turned off when the "versioning" was enabled. This system continually updated dashboards and our versions kept increasing. The version table is 30GB so this may be an extreme case but other users may also see this bug if they have implemented the same thing.
The text was updated successfully, but these errors were encountered: