Reduce number of Redis calls when expiring method caches in Repository model
Summary
RepositoryCacheAdapter
issues an individual expiry call for each method cache to be expired. This generates a lot of individual calls to Redis.
Improvements
Any updates to a repository should generate fewer Redis calls and therefore have less issues with network latency.
Risks
Might not expire things if it doesn't work.
Involved components
app/models/repository.rb
lib/gitlab/repository_cache.rb
lib/gitlab/repository_set_cache.rb
-
lib/gitlab/repository_hash_cache.rb
(being added in !24504 (merged)) lib/gitlab/repository_cache_adapter.rb