Invalidate cache for max assigned issues count on update
What does this MR do and why?
When user has many issues assigned, the count query can be slow and heavy. In #381867 (closed), we made a decision to count up to only 100 assigned issues (open) and display 99+. Currently this feature is behind a FF :limit_assigned_issues_count
.
While testing I realized I wasn't invalidating the redis cache for the count when a user gets assigned to/unassigned from an issue. This MR fixes this.
How to set up and validate locally
-
Enable
:limit_assigned_issues_count
Feature.enable(:limit_assigned_issues_count)
-
Observe the issues count in the navbar:
- Unassign the user from an issue and check the count is updated (refresh the page!)
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by euko