Merge pull request #87718 from wojtek-t/kubelet_not_watching_immutable_secret_configmaps
WatchBasedManager stops watching immutable objects
This commit is contained in:
@@ -57,7 +57,10 @@ func TestWatchBasedManager(t *testing.T) {
|
||||
return client.CoreV1().Secrets(namespace).Watch(context.TODO(), options)
|
||||
}
|
||||
newObj := func() runtime.Object { return &v1.Secret{} }
|
||||
store := manager.NewObjectCache(listObj, watchObj, newObj, schema.GroupResource{Group: "v1", Resource: "secrets"})
|
||||
// We want all watches to be up and running to stress test it.
|
||||
// So don't treat any secret as immutable here.
|
||||
isImmutable := func(_ runtime.Object) bool { return false }
|
||||
store := manager.NewObjectCache(listObj, watchObj, newObj, isImmutable, schema.GroupResource{Group: "v1", Resource: "secrets"})
|
||||
|
||||
// create 1000 secrets in parallel
|
||||
t.Log(time.Now(), "creating 1000 secrets")
|
||||
|
||||
Reference in New Issue
Block a user