From 3db0918eb8c4d8dfc4f1bb75f4ac84485b81a60e Mon Sep 17 00:00:00 2001 From: Ricardo Weir Date: Wed, 10 May 2023 15:47:27 -0700 Subject: [PATCH] Change cache default to false --- pkg/stores/partition/store.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/stores/partition/store.go b/pkg/stores/partition/store.go index 185a6cb5..4c25022c 100644 --- a/pkg/stores/partition/store.go +++ b/pkg/stores/partition/store.go @@ -29,7 +29,7 @@ const ( // Not related to the total size in memory of the cache, as any item could take any amount of memory. cacheSizeEnv = "CATTLE_REQUEST_CACHE_SIZE_INT" defaultCacheSize = 1000 - // Set to non-empty to disable list request caching entirely. + // Set to "false" to enable list request caching. cacheDisableEnv = "CATTLE_REQUEST_CACHE_DISABLED" ) @@ -60,7 +60,7 @@ func NewStore(partitioner Partitioner, asl accesscontrol.AccessSetLookup) *Store Partitioner: partitioner, asl: asl, } - if v := os.Getenv(cacheDisableEnv); v == "" { + if v := os.Getenv(cacheDisableEnv); v == "false" { s.listCache = cache.NewLRUExpireCache(cacheSize) } return s