We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 24c1232 commit 4ebfcdfCopy full SHA for 4ebfcdf
cmd/cache-offloader.go
@@ -18,9 +18,9 @@ import (
18
func getInMemoryStorage(cfg config.Config) http.Cacher {
19
switch strings.ToLower(cfg.CacheConfig.Strategy) {
20
case "lru":
21
- return storage.NewLRUCache(cfg.CacheConfig.Size)
+ return storage.NewLRUCache(cfg.CacheConfig.Size, 5*60 /*5 minutes*/)
22
case "lfu":
23
- storage.NewLFUCache(cfg.CacheConfig.Size)
+ storage.NewLFUCache(cfg.CacheConfig.Size, 5*60 /*5 minutes*/)
24
default:
25
log.Error().Msgf("Unknown cache strategy: %s", cfg.CacheConfig.Strategy)
26
log.Fatal().Msg("Supported cache strategies are LRU and LFU")
0 commit comments