Add failure handling of the desiredStateOfWorldPopulator start

Signed-off-by: PingWang <wang.ping5@zte.com.cn>
This commit is contained in:
PingWang 2022-07-01 13:56:33 +08:00
parent fa16bf8e12
commit c6b4725e55

View File

@ -108,7 +108,11 @@ var _ PluginManager = &pluginManager{}
func (pm *pluginManager) Run(sourcesReady config.SourcesReady, stopCh <-chan struct{}) {
defer runtime.HandleCrash()
pm.desiredStateOfWorldPopulator.Start(stopCh)
if err := pm.desiredStateOfWorldPopulator.Start(stopCh); err != nil {
klog.ErrorS(err, "The desired_state_of_world populator (plugin watcher) starts failed!")
return
}
klog.V(2).InfoS("The desired_state_of_world populator (plugin watcher) starts")
klog.InfoS("Starting Kubelet Plugin Manager")