Commit 19af5de8 authored by Kubernetes Submit Queue's avatar Kubernetes Submit Queue Committed by GitHub

Merge pull request #52633 from karataliu/ccm_defaultrrp

Automatic merge from submit-queue (batch tested with PRs 52751, 52898, 52633, 52611, 52609). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>.. Add default value for RouteReconciliationPeriod in cloud controller manager **What this PR does / why we need it**: Add default sync period value config for RouteReconciliationPeriod. For now the default value is 0, which means zero cooldown time. The value is taken from kube-controller-manager: https://github.com/kubernetes/kubernetes/blob/b2b079b95a867b560fd327cba56e7d3878f43dc3/cmd/kube-controller-manager/app/options/options.go#L73 **Which issue this PR fixes** **Special notes for your reviewer**: **Release note**:
parents b7c36dc7 5af2ac53
...@@ -45,19 +45,22 @@ type CloudControllerManagerServer struct { ...@@ -45,19 +45,22 @@ type CloudControllerManagerServer struct {
// NewCloudControllerManagerServer creates a new ExternalCMServer with a default config. // NewCloudControllerManagerServer creates a new ExternalCMServer with a default config.
func NewCloudControllerManagerServer() *CloudControllerManagerServer { func NewCloudControllerManagerServer() *CloudControllerManagerServer {
s := CloudControllerManagerServer{ s := CloudControllerManagerServer{
// Part of these default values also present in 'cmd/kube-controller-manager/app/options/options.go'.
// Please keep them in sync when doing update.
KubeControllerManagerConfiguration: componentconfig.KubeControllerManagerConfiguration{ KubeControllerManagerConfiguration: componentconfig.KubeControllerManagerConfiguration{
Port: ports.CloudControllerManagerPort, Port: ports.CloudControllerManagerPort,
Address: "0.0.0.0", Address: "0.0.0.0",
ConcurrentServiceSyncs: 1, ConcurrentServiceSyncs: 1,
MinResyncPeriod: metav1.Duration{Duration: 12 * time.Hour}, MinResyncPeriod: metav1.Duration{Duration: 12 * time.Hour},
NodeMonitorPeriod: metav1.Duration{Duration: 5 * time.Second}, NodeMonitorPeriod: metav1.Duration{Duration: 5 * time.Second},
ClusterName: "kubernetes", ClusterName: "kubernetes",
ConfigureCloudRoutes: true, ConfigureCloudRoutes: true,
ContentType: "application/vnd.kubernetes.protobuf", ContentType: "application/vnd.kubernetes.protobuf",
KubeAPIQPS: 20.0, KubeAPIQPS: 20.0,
KubeAPIBurst: 30, KubeAPIBurst: 30,
LeaderElection: leaderelectionconfig.DefaultLeaderElectionConfiguration(), LeaderElection: leaderelectionconfig.DefaultLeaderElectionConfiguration(),
ControllerStartInterval: metav1.Duration{Duration: 0 * time.Second}, ControllerStartInterval: metav1.Duration{Duration: 0 * time.Second},
RouteReconciliationPeriod: metav1.Duration{Duration: 10 * time.Second},
}, },
NodeStatusUpdateFrequency: metav1.Duration{Duration: 5 * time.Minute}, NodeStatusUpdateFrequency: metav1.Duration{Duration: 5 * time.Minute},
} }
......
...@@ -55,6 +55,8 @@ func NewCMServer() *CMServer { ...@@ -55,6 +55,8 @@ func NewCMServer() *CMServer {
} }
s := CMServer{ s := CMServer{
// Part of these default values also present in 'cmd/cloud-controller-manager/app/options/options.go'.
// Please keep them in sync when doing update.
KubeControllerManagerConfiguration: componentconfig.KubeControllerManagerConfiguration{ KubeControllerManagerConfiguration: componentconfig.KubeControllerManagerConfiguration{
Controllers: []string{"*"}, Controllers: []string{"*"},
Port: ports.ControllerManagerPort, Port: ports.ControllerManagerPort,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment