From c74aab649fc32680bc0afecbe238ff45148e9bdb Mon Sep 17 00:00:00 2001 From: Anthony Yeh Date: Tue, 7 Mar 2017 10:46:10 -0800 Subject: [PATCH] RC/RS: Mark lookup-cache-size flags as deprecated. --- cmd/kube-controller-manager/app/options/options.go | 6 +++++- pkg/apis/componentconfig/types.go | 5 +++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/cmd/kube-controller-manager/app/options/options.go b/cmd/kube-controller-manager/app/options/options.go index 86bfd072c50..fe8affcbda0 100644 --- a/cmd/kube-controller-manager/app/options/options.go +++ b/cmd/kube-controller-manager/app/options/options.go @@ -131,9 +131,13 @@ func (s *CMServer) AddFlags(fs *pflag.FlagSet, allControllers []string, disabled fs.Int32Var(&s.ConcurrentDeploymentSyncs, "concurrent-deployment-syncs", s.ConcurrentDeploymentSyncs, "The number of deployment objects that are allowed to sync concurrently. Larger number = more responsive deployments, but more CPU (and network) load") fs.Int32Var(&s.ConcurrentNamespaceSyncs, "concurrent-namespace-syncs", s.ConcurrentNamespaceSyncs, "The number of namespace objects that are allowed to sync concurrently. Larger number = more responsive namespace termination, but more CPU (and network) load") fs.Int32Var(&s.ConcurrentSATokenSyncs, "concurrent-serviceaccount-token-syncs", s.ConcurrentSATokenSyncs, "The number of service account token objects that are allowed to sync concurrently. Larger number = more responsive token generation, but more CPU (and network) load") + // TODO(#43388): Remove the following flag 6 months after v1.6.0 is released. fs.Int32Var(&s.LookupCacheSizeForRC, "replication-controller-lookup-cache-size", s.LookupCacheSizeForRC, "This flag is deprecated and will be removed in future releases. ReplicationController no longer requires a lookup cache.") + fs.MarkDeprecated("replication-controller-lookup-cache-size", "This flag is deprecated and will be removed in future releases. ReplicationController no longer requires a lookup cache.") + // TODO(#43388): Remove the following flag 6 months after v1.6.0 is released. fs.Int32Var(&s.LookupCacheSizeForRS, "replicaset-lookup-cache-size", s.LookupCacheSizeForRS, "This flag is deprecated and will be removed in future releases. ReplicaSet no longer requires a lookup cache.") - // TODO: Remove the following flag 6 months after v1.6.0 is released. + fs.MarkDeprecated("replicaset-lookup-cache-size", "This flag is deprecated and will be removed in future releases. ReplicaSet no longer requires a lookup cache.") + // TODO(#43388): Remove the following flag 6 months after v1.6.0 is released. fs.Int32Var(&s.LookupCacheSizeForDaemonSet, "daemonset-lookup-cache-size", s.LookupCacheSizeForDaemonSet, "This flag is deprecated and will be removed in future releases. DaemonSet no longer requires a lookup cache.") fs.MarkDeprecated("daemonset-lookup-cache-size", "This flag is deprecated and will be removed in future releases. DaemonSet no longer requires a lookup cache.") fs.DurationVar(&s.ServiceSyncPeriod.Duration, "service-sync-period", s.ServiceSyncPeriod.Duration, "The period for syncing services with their external load balancers") diff --git a/pkg/apis/componentconfig/types.go b/pkg/apis/componentconfig/types.go index aefc343e0af..919088b01a0 100644 --- a/pkg/apis/componentconfig/types.go +++ b/pkg/apis/componentconfig/types.go @@ -684,12 +684,17 @@ type KubeControllerManagerConfiguration struct { ConcurrentSATokenSyncs int32 // lookupCacheSizeForRC is the size of lookup cache for replication controllers. // Larger number = more responsive replica management, but more MEM load. + // TODO(#43388): Remove the following flag 6 months after v1.6.0 is released. + // DEPRECATED: This is no longer used. LookupCacheSizeForRC int32 // lookupCacheSizeForRS is the size of lookup cache for replicatsets. // Larger number = more responsive replica management, but more MEM load. + // TODO(#43388): Remove the following flag 6 months after v1.6.0 is released. + // DEPRECATED: This is no longer used. LookupCacheSizeForRS int32 // lookupCacheSizeForDaemonSet is the size of lookup cache for daemonsets. // Larger number = more responsive daemonset, but more MEM load. + // TODO(#43388): Remove the following flag 6 months after v1.6.0 is released. // DEPRECATED: This is no longer used. LookupCacheSizeForDaemonSet int32 // serviceSyncPeriod is the period for syncing services with their external