Merge pull request #3498 from pravisankar/ravi/sync-nodes-optional

Make periodic sync nodes from -cloud_provider/-machines optional.
This commit is contained in:
Deyuan Deng
2015-02-09 17:45:56 -05:00
7 changed files with 30 additions and 13 deletions

View File

@@ -203,7 +203,7 @@ func startComponents(manifestURL string) (apiServerURL string) {
nodeResources := &api.NodeResources{}
nodeController := nodeControllerPkg.NewNodeController(nil, "", machineList, nodeResources, cl, fakeKubeletClient{})
nodeController.Run(5*time.Second, 10)
nodeController.Run(5*time.Second, 10, true)
// Kubelet (localhost)
testRootDir := makeTempDirOrDie("kubelet_integ_1.")

View File

@@ -124,7 +124,7 @@ func runControllerManager(machineList []string, cl *client.Client, nodeMilliCPU,
}
kubeClient := &client.HTTPKubeletClient{Client: http.DefaultClient, Port: ports.KubeletPort}
nodeController := nodeControllerPkg.NewNodeController(nil, "", machineList, nodeResources, cl, kubeClient)
nodeController.Run(10*time.Second, 10)
nodeController.Run(10*time.Second, 10, true)
endpoints := service.NewEndpointController(cl)
go util.Forever(func() { endpoints.SyncServiceEndpoints() }, time.Second*10)