From 867d49569e41bb3d9c2319ac55d134ca851562e0 Mon Sep 17 00:00:00 2001 From: shashidharatd Date: Mon, 6 Mar 2017 02:58:10 +0530 Subject: [PATCH] Fix federation controller-manager initialization --- .../federation-controller/service/servicecontroller.go | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/federation/pkg/federation-controller/service/servicecontroller.go b/federation/pkg/federation-controller/service/servicecontroller.go index 3d0917b9b77..c765bb76410 100644 --- a/federation/pkg/federation-controller/service/servicecontroller.go +++ b/federation/pkg/federation-controller/service/servicecontroller.go @@ -403,10 +403,12 @@ func (s *ServiceController) Run(workers int, stopCh <-chan struct{}) error { go wait.Until(s.clusterEndpointWorker, time.Second, stopCh) go wait.Until(s.clusterServiceWorker, time.Second, stopCh) go wait.Until(s.clusterSyncLoop, time.Second, stopCh) - <-stopCh - glog.Infof("Shutting down Federation Service Controller") - s.queue.ShutDown() - s.federatedInformer.Stop() + go func() { + <-stopCh + glog.Infof("Shutting down Federation Service Controller") + s.queue.ShutDown() + s.federatedInformer.Stop() + }() return nil }