remove EventRecorder from ControllerParameters of pv base controller

This commit is contained in:
carlory
2023-11-01 13:47:23 +08:00
parent f5a5d83d7c
commit 58236aa3eb
2 changed files with 7 additions and 13 deletions

View File

@@ -232,13 +232,13 @@ func newTestController(ctx context.Context, kubeClient clientset.Interface, info
ClassInformer: informerFactory.Storage().V1().StorageClasses(),
PodInformer: informerFactory.Core().V1().Pods(),
NodeInformer: informerFactory.Core().V1().Nodes(),
EventRecorder: record.NewFakeRecorder(1000),
EnableDynamicProvisioning: enableDynamicProvisioning,
}
ctrl, err := NewController(ctx, params)
if err != nil {
return nil, fmt.Errorf("failed to construct persistentvolume controller: %v", err)
}
ctrl.eventRecorder = record.NewFakeRecorder(1000)
ctrl.volumeListerSynced = alwaysReady
ctrl.claimListerSynced = alwaysReady
ctrl.classListerSynced = alwaysReady