-
Notifications
You must be signed in to change notification settings - Fork 495
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 the caches and increase version when bugs are fixed #1625
Comments
Instead of adding versioning to our caches (what would the version be based on? Our internal release number? Mimir version? Commit hash? Manually when fixing a bug as you suggested?), Mimir could also flush the cache after rollout. For results cache with only a handful of query-frontends, that may be good-enough solution. |
I would increase the version each time a bug is fixed (or a features is introduced). There's no need to flush the cache in most of the releases, so I wouldn't do that. |
I think add version to the cache key makes sense. I also agree that it should be done only after a bug fix or a backward incompatible feature is introduced, not just at every rollout. |
This is my proposal: #1631 |
Is your feature request related to a problem? Please describe.
A customer complained about issues they were seeing in cached data, and after analysing it for a while, we found that #1542 was the cause for bad response being cached.
Even though the bug was fixed, the cached data stayed there for a while so the results were not reflecting the fix.
Describe the solution you'd like
Wrap our caches with something that would add a version to the keys, like this:
Then increase the version with which it's instantiated every time a bug is fixed.
Describe alternatives you've considered
Add version to each one of the cache usages instead, like here:
http://github.com/grafana/mimir/blob/f33cdfda71d99dc653842454389a04590fcb979e/pkg/frontend/querymiddleware/split_and_cache.go#L302-L313
The text was updated successfully, but these errors were encountered: