increase LRU cache size 8x for authorization webhook
1024 seems absurdly small for any normal deployment. At our 10000 byte entry size limit, this will consume max ~80 MB of memory. More realistic entry sizes are going to be less than a kB. Kubernetes-commit: fb33b2f42a9621e65883c92a3cb49a278d14c6cc
This commit is contained in:
parent
0e7fa4e989
commit
05faa1edc6
|
@ -95,7 +95,7 @@ func New(kubeConfigFile string, version string, authorizedTTL, unauthorizedTTL t
|
|||
func newWithBackoff(subjectAccessReview subjectAccessReviewer, authorizedTTL, unauthorizedTTL, initialBackoff time.Duration) (*WebhookAuthorizer, error) {
|
||||
return &WebhookAuthorizer{
|
||||
subjectAccessReview: subjectAccessReview,
|
||||
responseCache: cache.NewLRUExpireCache(1024),
|
||||
responseCache: cache.NewLRUExpireCache(8192),
|
||||
authorizedTTL: authorizedTTL,
|
||||
unauthorizedTTL: unauthorizedTTL,
|
||||
initialBackoff: initialBackoff,
|
||||
|
|
Loading…
Reference in New Issue