From c35fd33f42d28ad01cd8e2a811b7fe5f3750230a Mon Sep 17 00:00:00 2001 From: Quan Tian Date: Thu, 19 Sep 2019 14:48:01 +0800 Subject: [PATCH] Fix wrong comments and inaccurate logs in endpointslice_controller --- .../endpointslice/endpointslice_controller.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/pkg/controller/endpointslice/endpointslice_controller.go b/pkg/controller/endpointslice/endpointslice_controller.go index e956530dcd3..9ad83851063 100644 --- a/pkg/controller/endpointslice/endpointslice_controller.go +++ b/pkg/controller/endpointslice/endpointslice_controller.go @@ -137,14 +137,14 @@ type Controller struct { // Added as a member to the struct to allow injection for testing. podsSynced cache.InformerSynced - // endpointSliceLister is able to list/get pods and is populated by the + // endpointSliceLister is able to list/get endpoint slices and is populated by the // shared informer passed to NewController endpointSliceLister discoverylisters.EndpointSliceLister // endpointSlicesSynced returns true if the endpoint slice shared informer has been synced at least once. // Added as a member to the struct to allow injection for testing. endpointSlicesSynced cache.InformerSynced - // nodeLister is able to list/get pods and is populated by the + // nodeLister is able to list/get nodes and is populated by the // shared informer passed to NewController nodeLister corelisters.NodeLister // nodesSynced returns true if the node shared informer has been synced at least once. @@ -159,7 +159,7 @@ type Controller struct { triggerTimeTracker *endpointutil.TriggerTimeTracker // Services that need to be updated. A channel is inappropriate here, - // because it allowes services with lots of pods to be serviced much + // because it allows services with lots of pods to be serviced much // more often than services with few pods; it also would cause a // service that's inserted multiple times to be processed more than // necessary. @@ -179,8 +179,8 @@ func (c *Controller) Run(workers int, stopCh <-chan struct{}) { defer utilruntime.HandleCrash() defer c.queue.ShutDown() - klog.Infof("Starting endpoint controller") - defer klog.Infof("Shutting down endpoint controller") + klog.Infof("Starting endpoint slice controller") + defer klog.Infof("Shutting down endpoint slice controller") if !cache.WaitForNamedCacheSync("endpoint_slice", stopCh, c.podsSynced, c.servicesSynced) { return