mirror of
https://github.com/kubernetes/kubernetes.git
synced 2026-02-18 18:28:18 -05:00
Make ConcurrentResourceClaimSyncs configurable (#134701)
* DRA resource claim controller: configurable number of workers It might never be necessary to change the default, but it is hard to be sure. It's better to have the option, just in case. * generate files * resourceclaimcontroller: normalize validation error message * Update cmd/kube-controller-manager/app/options/resourceclaimcontroller.go Co-authored-by: Jordan Liggitt <jordan@liggitt.net> --------- Co-authored-by: Patrick Ohly <patrick.ohly@intel.com> Co-authored-by: Jordan Liggitt <jordan@liggitt.net>
This commit is contained in:
parent
c4881eae3b
commit
a816a7b1d8
23 changed files with 531 additions and 5 deletions
|
|
@ -218,6 +218,7 @@ API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,K
|
|||
API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,KubeControllerManagerConfiguration,PodGCController
|
||||
API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,KubeControllerManagerConfiguration,ReplicaSetController
|
||||
API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,KubeControllerManagerConfiguration,ReplicationController
|
||||
API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,KubeControllerManagerConfiguration,ResourceClaimController
|
||||
API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,KubeControllerManagerConfiguration,ResourceQuotaController
|
||||
API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,KubeControllerManagerConfiguration,SAController
|
||||
API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,KubeControllerManagerConfiguration,ServiceController
|
||||
|
|
@ -251,6 +252,7 @@ API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,P
|
|||
API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,PodGCControllerConfiguration,TerminatedPodGCThreshold
|
||||
API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,ReplicaSetControllerConfiguration,ConcurrentRSSyncs
|
||||
API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,ReplicationControllerConfiguration,ConcurrentRCSyncs
|
||||
API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,ResourceClaimControllerConfiguration,ConcurrentSyncs
|
||||
API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,ResourceQuotaControllerConfiguration,ConcurrentResourceQuotaSyncs
|
||||
API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,ResourceQuotaControllerConfiguration,ResourceQuotaSyncPeriod
|
||||
API rule violation: names_match,k8s.io/kube-controller-manager/config/v1alpha1,SAControllerConfiguration,ConcurrentSATokenSyncs
|
||||
|
|
|
|||
|
|
@ -460,8 +460,6 @@ func newEphemeralVolumeController(ctx context.Context, controllerContext Control
|
|||
}, controllerName), nil
|
||||
}
|
||||
|
||||
const defaultResourceClaimControllerWorkers = 50
|
||||
|
||||
func newResourceClaimControllerDescriptor() *ControllerDescriptor {
|
||||
return &ControllerDescriptor{
|
||||
name: names.ResourceClaimController,
|
||||
|
|
@ -494,7 +492,7 @@ func newResourceClaimController(ctx context.Context, controllerContext Controlle
|
|||
}
|
||||
|
||||
return newControllerLoop(func(ctx context.Context) {
|
||||
ephemeralController.Run(ctx, defaultResourceClaimControllerWorkers)
|
||||
ephemeralController.Run(ctx, int(controllerContext.ComponentConfig.ResourceClaimController.ConcurrentSyncs))
|
||||
}, controllerName), nil
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -78,6 +78,7 @@ type KubeControllerManagerOptions struct {
|
|||
DaemonSetController *DaemonSetControllerOptions
|
||||
DeploymentController *DeploymentControllerOptions
|
||||
DeviceTaintEvictionController *DeviceTaintEvictionControllerOptions
|
||||
ResourceClaimController *ResourceClaimControllerOptions
|
||||
StatefulSetController *StatefulSetControllerOptions
|
||||
DeprecatedFlags *DeprecatedControllerOptions
|
||||
EndpointController *EndpointControllerOptions
|
||||
|
|
@ -155,6 +156,9 @@ func NewKubeControllerManagerOptions() (*KubeControllerManagerOptions, error) {
|
|||
DeviceTaintEvictionController: &DeviceTaintEvictionControllerOptions{
|
||||
&componentConfig.DeviceTaintEvictionController,
|
||||
},
|
||||
ResourceClaimController: &ResourceClaimControllerOptions{
|
||||
&componentConfig.ResourceClaimController,
|
||||
},
|
||||
StatefulSetController: &StatefulSetControllerOptions{
|
||||
&componentConfig.StatefulSetController,
|
||||
},
|
||||
|
|
@ -277,6 +281,7 @@ func (s *KubeControllerManagerOptions) Flags(allControllers []string, disabledBy
|
|||
s.CSRSigningController.AddFlags(fss.FlagSet(names.CertificateSigningRequestSigningController))
|
||||
s.DeploymentController.AddFlags(fss.FlagSet(names.DeploymentController))
|
||||
s.DeviceTaintEvictionController.AddFlags(fss.FlagSet(names.DeviceTaintEvictionController))
|
||||
s.ResourceClaimController.AddFlags(fss.FlagSet(names.ResourceClaimController))
|
||||
s.StatefulSetController.AddFlags(fss.FlagSet(names.StatefulSetController))
|
||||
s.DaemonSetController.AddFlags(fss.FlagSet(names.DaemonSetController))
|
||||
s.DeprecatedFlags.AddFlags(fss.FlagSet("deprecated"))
|
||||
|
|
@ -349,6 +354,9 @@ func (s *KubeControllerManagerOptions) ApplyTo(c *kubecontrollerconfig.Config, a
|
|||
if err := s.DeviceTaintEvictionController.ApplyTo(&c.ComponentConfig.DeviceTaintEvictionController); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := s.ResourceClaimController.ApplyTo(&c.ComponentConfig.ResourceClaimController); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := s.StatefulSetController.ApplyTo(&c.ComponentConfig.StatefulSetController); err != nil {
|
||||
return err
|
||||
}
|
||||
|
|
@ -449,6 +457,7 @@ func (s *KubeControllerManagerOptions) Validate(allControllers []string, disable
|
|||
errs = append(errs, s.DaemonSetController.Validate()...)
|
||||
errs = append(errs, s.DeploymentController.Validate()...)
|
||||
errs = append(errs, s.DeviceTaintEvictionController.Validate()...)
|
||||
errs = append(errs, s.ResourceClaimController.Validate()...)
|
||||
errs = append(errs, s.StatefulSetController.Validate()...)
|
||||
errs = append(errs, s.DeprecatedFlags.Validate()...)
|
||||
errs = append(errs, s.EndpointController.Validate()...)
|
||||
|
|
|
|||
|
|
@ -69,6 +69,7 @@ import (
|
|||
podgcconfig "k8s.io/kubernetes/pkg/controller/podgc/config"
|
||||
replicasetconfig "k8s.io/kubernetes/pkg/controller/replicaset/config"
|
||||
replicationconfig "k8s.io/kubernetes/pkg/controller/replication/config"
|
||||
resourceclaimconfig "k8s.io/kubernetes/pkg/controller/resourceclaim/config"
|
||||
resourcequotaconfig "k8s.io/kubernetes/pkg/controller/resourcequota/config"
|
||||
serviceaccountconfig "k8s.io/kubernetes/pkg/controller/serviceaccount/config"
|
||||
statefulsetconfig "k8s.io/kubernetes/pkg/controller/statefulset/config"
|
||||
|
|
@ -100,6 +101,7 @@ var args = []string{
|
|||
"--cluster-signing-legacy-unknown-key-file=/cluster-signing-legacy-unknown/key-file",
|
||||
"--concurrent-deployment-syncs=10",
|
||||
"--concurrent-device-taint-eviction-syncs=10",
|
||||
"--concurrent-resourceclaim-syncs=10",
|
||||
"--concurrent-daemonset-syncs=10",
|
||||
"--concurrent-horizontal-pod-autoscaler-syncs=10",
|
||||
"--concurrent-statefulset-syncs=15",
|
||||
|
|
@ -280,6 +282,11 @@ func TestAddFlags(t *testing.T) {
|
|||
ConcurrentSyncs: 10,
|
||||
},
|
||||
},
|
||||
ResourceClaimController: &ResourceClaimControllerOptions{
|
||||
&resourceclaimconfig.ResourceClaimControllerConfiguration{
|
||||
ConcurrentSyncs: 10,
|
||||
},
|
||||
},
|
||||
StatefulSetController: &StatefulSetControllerOptions{
|
||||
&statefulsetconfig.StatefulSetControllerConfiguration{
|
||||
ConcurrentStatefulSetSyncs: 15,
|
||||
|
|
@ -634,6 +641,9 @@ func TestApplyTo(t *testing.T) {
|
|||
DeviceTaintEvictionController: devicetaintevictionconfig.DeviceTaintEvictionControllerConfiguration{
|
||||
ConcurrentSyncs: 10,
|
||||
},
|
||||
ResourceClaimController: resourceclaimconfig.ResourceClaimControllerConfiguration{
|
||||
ConcurrentSyncs: 10,
|
||||
},
|
||||
StatefulSetController: statefulsetconfig.StatefulSetControllerConfiguration{
|
||||
ConcurrentStatefulSetSyncs: 15,
|
||||
},
|
||||
|
|
@ -1281,6 +1291,15 @@ func TestValidateControllersOptions(t *testing.T) {
|
|||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "ResourceClaimControllerOptions",
|
||||
expectErrors: false,
|
||||
options: &ResourceClaimControllerOptions{
|
||||
&resourceclaimconfig.ResourceClaimControllerConfiguration{
|
||||
ConcurrentSyncs: 10,
|
||||
},
|
||||
},
|
||||
},
|
||||
{
|
||||
name: "DeprecatedControllerOptions",
|
||||
expectErrors: false,
|
||||
|
|
|
|||
|
|
@ -0,0 +1,63 @@
|
|||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
package options
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
"github.com/spf13/pflag"
|
||||
|
||||
resourceclaimconfig "k8s.io/kubernetes/pkg/controller/resourceclaim/config"
|
||||
)
|
||||
|
||||
// ResourceClaimControllerOptions holds the ResourceClaimController options.
|
||||
type ResourceClaimControllerOptions struct {
|
||||
*resourceclaimconfig.ResourceClaimControllerConfiguration
|
||||
}
|
||||
|
||||
// AddFlags adds flags related to ResourceClaimController for controller manager to the specified FlagSet.
|
||||
func (o *ResourceClaimControllerOptions) AddFlags(fs *pflag.FlagSet) {
|
||||
if o == nil {
|
||||
return
|
||||
}
|
||||
|
||||
fs.Int32Var(&o.ConcurrentSyncs, "concurrent-resourceclaim-syncs", o.ConcurrentSyncs, "The number of operations (creating or deleting ResourceClaims) allowed to run concurrently. Larger number = more responsive, but more CPU (and network) load")
|
||||
}
|
||||
|
||||
// ApplyTo fills up ResourceClaimController config with options.
|
||||
func (o *ResourceClaimControllerOptions) ApplyTo(cfg *resourceclaimconfig.ResourceClaimControllerConfiguration) error {
|
||||
if o == nil {
|
||||
return nil
|
||||
}
|
||||
|
||||
cfg.ConcurrentSyncs = o.ConcurrentSyncs
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
// Validate checks validation of ResourceClaimControllerOptions.
|
||||
func (o *ResourceClaimControllerOptions) Validate() []error {
|
||||
if o == nil {
|
||||
return nil
|
||||
}
|
||||
|
||||
var errs []error
|
||||
if o.ConcurrentSyncs <= 0 {
|
||||
errs = append(errs, fmt.Errorf("concurrent-resourceclaim-syncs must be larger than 0, got %d", o.ConcurrentSyncs))
|
||||
}
|
||||
return errs
|
||||
}
|
||||
|
|
@ -38,6 +38,7 @@ import (
|
|||
podgcconfig "k8s.io/kubernetes/pkg/controller/podgc/config"
|
||||
replicasetconfig "k8s.io/kubernetes/pkg/controller/replicaset/config"
|
||||
replicationconfig "k8s.io/kubernetes/pkg/controller/replication/config"
|
||||
resourceclaimconfig "k8s.io/kubernetes/pkg/controller/resourceclaim/config"
|
||||
resourcequotaconfig "k8s.io/kubernetes/pkg/controller/resourcequota/config"
|
||||
serviceaccountconfig "k8s.io/kubernetes/pkg/controller/serviceaccount/config"
|
||||
statefulsetconfig "k8s.io/kubernetes/pkg/controller/statefulset/config"
|
||||
|
|
@ -139,6 +140,8 @@ type KubeControllerManagerConfiguration struct {
|
|||
// ValidatingAdmissionPolicyStatusControllerConfiguration holds configuration for
|
||||
// ValidatingAdmissionPolicyStatusController related features.
|
||||
ValidatingAdmissionPolicyStatusController validatingadmissionpolicystatusconfig.ValidatingAdmissionPolicyStatusControllerConfiguration
|
||||
// ResourceClaimControllerConfiguration contains elements configuring the resource claim controller.
|
||||
ResourceClaimController resourceclaimconfig.ResourceClaimControllerConfiguration
|
||||
}
|
||||
|
||||
// DeprecatedControllerConfiguration contains elements be deprecated.
|
||||
|
|
|
|||
|
|
@ -38,6 +38,7 @@ import (
|
|||
podgcconfigv1alpha1 "k8s.io/kubernetes/pkg/controller/podgc/config/v1alpha1"
|
||||
replicasetconfigv1alpha1 "k8s.io/kubernetes/pkg/controller/replicaset/config/v1alpha1"
|
||||
replicationconfigv1alpha1 "k8s.io/kubernetes/pkg/controller/replication/config/v1alpha1"
|
||||
resourceclaimconfigv1alpha1 "k8s.io/kubernetes/pkg/controller/resourceclaim/config/v1alpha1"
|
||||
resourcequotaconfigv1alpha1 "k8s.io/kubernetes/pkg/controller/resourcequota/config/v1alpha1"
|
||||
serviceaccountconfigv1alpha1 "k8s.io/kubernetes/pkg/controller/serviceaccount/config/v1alpha1"
|
||||
statefulsetconfigv1alpha1 "k8s.io/kubernetes/pkg/controller/statefulset/config/v1alpha1"
|
||||
|
|
@ -74,6 +75,8 @@ func SetDefaults_KubeControllerManagerConfiguration(obj *kubectrlmgrconfigv1alph
|
|||
deploymentconfigv1alpha1.RecommendedDefaultDeploymentControllerConfiguration(&obj.DeploymentController)
|
||||
// Use the default RecommendedDefaultDeviceTaintEvictionControllerConfiguration options
|
||||
devicetaintevictionconfigv1alpha1.RecommendedDefaultDeviceTaintEvictionControllerConfiguration(&obj.DeviceTaintEvictionController)
|
||||
// Use the default RecommendedDefaultResourceClaimControllerConfiguration options
|
||||
resourceclaimconfigv1alpha1.RecommendedDefaultResourceClaimControllerConfiguration(&obj.ResourceClaimController)
|
||||
// Use the default RecommendedDefaultStatefulSetControllerConfiguration options
|
||||
statefulsetconfigv1alpha1.RecommendedDefaultStatefulSetControllerConfiguration(&obj.StatefulSetController)
|
||||
// Use the default RecommendedDefaultEndpointControllerConfiguration options
|
||||
|
|
|
|||
|
|
@ -47,6 +47,7 @@ import (
|
|||
podgcconfigv1alpha1 "k8s.io/kubernetes/pkg/controller/podgc/config/v1alpha1"
|
||||
replicasetconfigv1alpha1 "k8s.io/kubernetes/pkg/controller/replicaset/config/v1alpha1"
|
||||
replicationconfigv1alpha1 "k8s.io/kubernetes/pkg/controller/replication/config/v1alpha1"
|
||||
resourceclaimconfigv1alpha1 "k8s.io/kubernetes/pkg/controller/resourceclaim/config/v1alpha1"
|
||||
resourcequotaconfigv1alpha1 "k8s.io/kubernetes/pkg/controller/resourcequota/config/v1alpha1"
|
||||
serviceaccountconfigv1alpha1 "k8s.io/kubernetes/pkg/controller/serviceaccount/config/v1alpha1"
|
||||
statefulsetconfigv1alpha1 "k8s.io/kubernetes/pkg/controller/statefulset/config/v1alpha1"
|
||||
|
|
@ -228,6 +229,9 @@ func autoConvert_v1alpha1_KubeControllerManagerConfiguration_To_config_KubeContr
|
|||
if err := devicetaintevictionconfigv1alpha1.Convert_v1alpha1_DeviceTaintEvictionControllerConfiguration_To_config_DeviceTaintEvictionControllerConfiguration(&in.DeviceTaintEvictionController, &out.DeviceTaintEvictionController, s); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := resourceclaimconfigv1alpha1.Convert_v1alpha1_ResourceClaimControllerConfiguration_To_config_ResourceClaimControllerConfiguration(&in.ResourceClaimController, &out.ResourceClaimController, s); err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
@ -327,6 +331,9 @@ func autoConvert_config_KubeControllerManagerConfiguration_To_v1alpha1_KubeContr
|
|||
if err := validatingadmissionpolicystatusconfigv1alpha1.Convert_config_ValidatingAdmissionPolicyStatusControllerConfiguration_To_v1alpha1_ValidatingAdmissionPolicyStatusControllerConfiguration(&in.ValidatingAdmissionPolicyStatusController, &out.ValidatingAdmissionPolicyStatusController, s); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := resourceclaimconfigv1alpha1.Convert_config_ResourceClaimControllerConfiguration_To_v1alpha1_ResourceClaimControllerConfiguration(&in.ResourceClaimController, &out.ResourceClaimController, s); err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -75,6 +75,7 @@ func (in *KubeControllerManagerConfiguration) DeepCopyInto(out *KubeControllerMa
|
|||
out.StatefulSetController = in.StatefulSetController
|
||||
out.TTLAfterFinishedController = in.TTLAfterFinishedController
|
||||
out.ValidatingAdmissionPolicyStatusController = in.ValidatingAdmissionPolicyStatusController
|
||||
out.ResourceClaimController = in.ResourceClaimController
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
19
pkg/controller/resourceclaim/config/doc.go
Normal file
19
pkg/controller/resourceclaim/config/doc.go
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// +k8s:deepcopy-gen=package
|
||||
|
||||
package config
|
||||
26
pkg/controller/resourceclaim/config/types.go
Normal file
26
pkg/controller/resourceclaim/config/types.go
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
package config
|
||||
|
||||
// ResourceClaimControllerConfiguration contains elements configuring the resource claim controller.
|
||||
type ResourceClaimControllerConfiguration struct {
|
||||
// ConcurrentSyncs is the number of operations (deleting a pod, updating a ResourcClaim status, etc.)
|
||||
// that will be done concurrently. Larger number = processing, but more CPU (and network) load.
|
||||
//
|
||||
// The default is 50.
|
||||
ConcurrentSyncs int32
|
||||
}
|
||||
40
pkg/controller/resourceclaim/config/v1alpha1/conversion.go
Normal file
40
pkg/controller/resourceclaim/config/v1alpha1/conversion.go
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
package v1alpha1
|
||||
|
||||
import (
|
||||
"k8s.io/apimachinery/pkg/conversion"
|
||||
"k8s.io/kube-controller-manager/config/v1alpha1"
|
||||
"k8s.io/kubernetes/pkg/controller/resourceclaim/config"
|
||||
)
|
||||
|
||||
// Important! The public back-and-forth conversion functions for the types in this package
|
||||
// with ResourceClaimControllerConfiguration types need to be manually exposed like this in order for
|
||||
// other packages that reference this package to be able to call these conversion functions
|
||||
// in an autogenerated manner.
|
||||
// TODO: Fix the bug in conversion-gen so it automatically discovers these Convert_* functions
|
||||
// in autogenerated code as well.
|
||||
|
||||
// Convert_v1alpha1_ResourceClaimControllerConfiguration_To_config_ResourceClaimControllerConfiguration is an autogenerated conversion function.
|
||||
func Convert_v1alpha1_ResourceClaimControllerConfiguration_To_config_ResourceClaimControllerConfiguration(in *v1alpha1.ResourceClaimControllerConfiguration, out *config.ResourceClaimControllerConfiguration, s conversion.Scope) error {
|
||||
return autoConvert_v1alpha1_ResourceClaimControllerConfiguration_To_config_ResourceClaimControllerConfiguration(in, out, s)
|
||||
}
|
||||
|
||||
// Convert_config_ResourceClaimControllerConfiguration_To_v1alpha1_ResourceClaimControllerConfiguration is an autogenerated conversion function.
|
||||
func Convert_config_ResourceClaimControllerConfiguration_To_v1alpha1_ResourceClaimControllerConfiguration(in *config.ResourceClaimControllerConfiguration, out *v1alpha1.ResourceClaimControllerConfiguration, s conversion.Scope) error {
|
||||
return autoConvert_config_ResourceClaimControllerConfiguration_To_v1alpha1_ResourceClaimControllerConfiguration(in, out, s)
|
||||
}
|
||||
38
pkg/controller/resourceclaim/config/v1alpha1/defaults.go
Normal file
38
pkg/controller/resourceclaim/config/v1alpha1/defaults.go
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
package v1alpha1
|
||||
|
||||
import (
|
||||
kubectrlmgrconfigv1alpha1 "k8s.io/kube-controller-manager/config/v1alpha1"
|
||||
)
|
||||
|
||||
// RecommendedDefaultResourceClaimControllerConfiguration defaults a pointer to a
|
||||
// ResourceClaimControllerConfiguration struct. This will set the recommended default
|
||||
// values, but they may be subject to change between API versions. This function
|
||||
// is intentionally not registered in the scheme as a "normal" `SetDefaults_Foo`
|
||||
// function to allow consumers of this type to set whatever defaults for their
|
||||
// embedded configs. Forcing consumers to use these defaults would be problematic
|
||||
// as defaulting in the scheme is done as part of the conversion, and there would
|
||||
// be no easy way to opt-out. Instead, if you want to use this defaulting method
|
||||
// run it in your wrapper struct of this type in its `SetDefaults_` method.
|
||||
func RecommendedDefaultResourceClaimControllerConfiguration(obj *kubectrlmgrconfigv1alpha1.ResourceClaimControllerConfiguration) {
|
||||
if obj.ConcurrentSyncs == 0 {
|
||||
// 50 workers were needed to pass the 1000 simulated node DRA test (#133113).
|
||||
// The workers are mostly just idle unless some real work has to be done.
|
||||
obj.ConcurrentSyncs = 50
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,31 @@
|
|||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
package v1alpha1
|
||||
|
||||
import (
|
||||
"testing"
|
||||
|
||||
kubectrlmgrconfigv1alpha1 "k8s.io/kube-controller-manager/config/v1alpha1"
|
||||
)
|
||||
|
||||
func TestRecommendedDefaultResourceClaimControllerConfiguration(t *testing.T) {
|
||||
config := new(kubectrlmgrconfigv1alpha1.ResourceClaimControllerConfiguration)
|
||||
RecommendedDefaultResourceClaimControllerConfiguration(config)
|
||||
if config.ConcurrentSyncs != 50 {
|
||||
t.Errorf("incorrect default value, expected 50 but got %v", config.ConcurrentSyncs)
|
||||
}
|
||||
}
|
||||
21
pkg/controller/resourceclaim/config/v1alpha1/doc.go
Normal file
21
pkg/controller/resourceclaim/config/v1alpha1/doc.go
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// +k8s:deepcopy-gen=package
|
||||
// +k8s:conversion-gen=k8s.io/kubernetes/pkg/controller/resourceclaim/config
|
||||
// +k8s:conversion-gen-external-types=k8s.io/kube-controller-manager/config/v1alpha1
|
||||
|
||||
package v1alpha1
|
||||
31
pkg/controller/resourceclaim/config/v1alpha1/register.go
Normal file
31
pkg/controller/resourceclaim/config/v1alpha1/register.go
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
package v1alpha1
|
||||
|
||||
import (
|
||||
"k8s.io/apimachinery/pkg/runtime"
|
||||
)
|
||||
|
||||
var (
|
||||
// SchemeBuilder is the scheme builder with scheme init functions to run for this API package
|
||||
SchemeBuilder runtime.SchemeBuilder
|
||||
// localSchemeBuilder extends the SchemeBuilder instance with the external types. In this package,
|
||||
// defaulting and conversion init funcs are registered as well.
|
||||
localSchemeBuilder = &SchemeBuilder
|
||||
// AddToScheme is a global function that registers this API group & version to a scheme
|
||||
AddToScheme = localSchemeBuilder.AddToScheme
|
||||
)
|
||||
92
pkg/controller/resourceclaim/config/v1alpha1/zz_generated.conversion.go
generated
Normal file
92
pkg/controller/resourceclaim/config/v1alpha1/zz_generated.conversion.go
generated
Normal file
|
|
@ -0,0 +1,92 @@
|
|||
//go:build !ignore_autogenerated
|
||||
// +build !ignore_autogenerated
|
||||
|
||||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by conversion-gen. DO NOT EDIT.
|
||||
|
||||
package v1alpha1
|
||||
|
||||
import (
|
||||
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
|
||||
conversion "k8s.io/apimachinery/pkg/conversion"
|
||||
runtime "k8s.io/apimachinery/pkg/runtime"
|
||||
configv1alpha1 "k8s.io/kube-controller-manager/config/v1alpha1"
|
||||
config "k8s.io/kubernetes/pkg/controller/resourceclaim/config"
|
||||
)
|
||||
|
||||
func init() {
|
||||
localSchemeBuilder.Register(RegisterConversions)
|
||||
}
|
||||
|
||||
// RegisterConversions adds conversion functions to the given scheme.
|
||||
// Public to allow building arbitrary schemes.
|
||||
func RegisterConversions(s *runtime.Scheme) error {
|
||||
if err := s.AddGeneratedConversionFunc((*configv1alpha1.GroupResource)(nil), (*v1.GroupResource)(nil), func(a, b interface{}, scope conversion.Scope) error {
|
||||
return Convert_v1alpha1_GroupResource_To_v1_GroupResource(a.(*configv1alpha1.GroupResource), b.(*v1.GroupResource), scope)
|
||||
}); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := s.AddGeneratedConversionFunc((*v1.GroupResource)(nil), (*configv1alpha1.GroupResource)(nil), func(a, b interface{}, scope conversion.Scope) error {
|
||||
return Convert_v1_GroupResource_To_v1alpha1_GroupResource(a.(*v1.GroupResource), b.(*configv1alpha1.GroupResource), scope)
|
||||
}); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := s.AddConversionFunc((*config.ResourceClaimControllerConfiguration)(nil), (*configv1alpha1.ResourceClaimControllerConfiguration)(nil), func(a, b interface{}, scope conversion.Scope) error {
|
||||
return Convert_config_ResourceClaimControllerConfiguration_To_v1alpha1_ResourceClaimControllerConfiguration(a.(*config.ResourceClaimControllerConfiguration), b.(*configv1alpha1.ResourceClaimControllerConfiguration), scope)
|
||||
}); err != nil {
|
||||
return err
|
||||
}
|
||||
if err := s.AddConversionFunc((*configv1alpha1.ResourceClaimControllerConfiguration)(nil), (*config.ResourceClaimControllerConfiguration)(nil), func(a, b interface{}, scope conversion.Scope) error {
|
||||
return Convert_v1alpha1_ResourceClaimControllerConfiguration_To_config_ResourceClaimControllerConfiguration(a.(*configv1alpha1.ResourceClaimControllerConfiguration), b.(*config.ResourceClaimControllerConfiguration), scope)
|
||||
}); err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func autoConvert_v1alpha1_GroupResource_To_v1_GroupResource(in *configv1alpha1.GroupResource, out *v1.GroupResource, s conversion.Scope) error {
|
||||
out.Group = in.Group
|
||||
out.Resource = in.Resource
|
||||
return nil
|
||||
}
|
||||
|
||||
// Convert_v1alpha1_GroupResource_To_v1_GroupResource is an autogenerated conversion function.
|
||||
func Convert_v1alpha1_GroupResource_To_v1_GroupResource(in *configv1alpha1.GroupResource, out *v1.GroupResource, s conversion.Scope) error {
|
||||
return autoConvert_v1alpha1_GroupResource_To_v1_GroupResource(in, out, s)
|
||||
}
|
||||
|
||||
func autoConvert_v1_GroupResource_To_v1alpha1_GroupResource(in *v1.GroupResource, out *configv1alpha1.GroupResource, s conversion.Scope) error {
|
||||
out.Group = in.Group
|
||||
out.Resource = in.Resource
|
||||
return nil
|
||||
}
|
||||
|
||||
// Convert_v1_GroupResource_To_v1alpha1_GroupResource is an autogenerated conversion function.
|
||||
func Convert_v1_GroupResource_To_v1alpha1_GroupResource(in *v1.GroupResource, out *configv1alpha1.GroupResource, s conversion.Scope) error {
|
||||
return autoConvert_v1_GroupResource_To_v1alpha1_GroupResource(in, out, s)
|
||||
}
|
||||
|
||||
func autoConvert_v1alpha1_ResourceClaimControllerConfiguration_To_config_ResourceClaimControllerConfiguration(in *configv1alpha1.ResourceClaimControllerConfiguration, out *config.ResourceClaimControllerConfiguration, s conversion.Scope) error {
|
||||
out.ConcurrentSyncs = in.ConcurrentSyncs
|
||||
return nil
|
||||
}
|
||||
|
||||
func autoConvert_config_ResourceClaimControllerConfiguration_To_v1alpha1_ResourceClaimControllerConfiguration(in *config.ResourceClaimControllerConfiguration, out *configv1alpha1.ResourceClaimControllerConfiguration, s conversion.Scope) error {
|
||||
out.ConcurrentSyncs = in.ConcurrentSyncs
|
||||
return nil
|
||||
}
|
||||
22
pkg/controller/resourceclaim/config/v1alpha1/zz_generated.deepcopy.go
generated
Normal file
22
pkg/controller/resourceclaim/config/v1alpha1/zz_generated.deepcopy.go
generated
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
//go:build !ignore_autogenerated
|
||||
// +build !ignore_autogenerated
|
||||
|
||||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by deepcopy-gen. DO NOT EDIT.
|
||||
|
||||
package v1alpha1
|
||||
38
pkg/controller/resourceclaim/config/zz_generated.deepcopy.go
generated
Normal file
38
pkg/controller/resourceclaim/config/zz_generated.deepcopy.go
generated
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
//go:build !ignore_autogenerated
|
||||
// +build !ignore_autogenerated
|
||||
|
||||
/*
|
||||
Copyright The Kubernetes Authors.
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
// Code generated by deepcopy-gen. DO NOT EDIT.
|
||||
|
||||
package config
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *ResourceClaimControllerConfiguration) DeepCopyInto(out *ResourceClaimControllerConfiguration) {
|
||||
*out = *in
|
||||
return
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ResourceClaimControllerConfiguration.
|
||||
func (in *ResourceClaimControllerConfiguration) DeepCopy() *ResourceClaimControllerConfiguration {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(ResourceClaimControllerConfiguration)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
34
pkg/generated/openapi/zz_generated.openapi.go
generated
34
pkg/generated/openapi/zz_generated.openapi.go
generated
|
|
@ -1370,6 +1370,7 @@ func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenA
|
|||
kubecontrollermanagerconfigv1alpha1.PodGCControllerConfiguration{}.OpenAPIModelName(): schema_k8sio_kube_controller_manager_config_v1alpha1_PodGCControllerConfiguration(ref),
|
||||
kubecontrollermanagerconfigv1alpha1.ReplicaSetControllerConfiguration{}.OpenAPIModelName(): schema_k8sio_kube_controller_manager_config_v1alpha1_ReplicaSetControllerConfiguration(ref),
|
||||
kubecontrollermanagerconfigv1alpha1.ReplicationControllerConfiguration{}.OpenAPIModelName(): schema_k8sio_kube_controller_manager_config_v1alpha1_ReplicationControllerConfiguration(ref),
|
||||
kubecontrollermanagerconfigv1alpha1.ResourceClaimControllerConfiguration{}.OpenAPIModelName(): schema_k8sio_kube_controller_manager_config_v1alpha1_ResourceClaimControllerConfiguration(ref),
|
||||
kubecontrollermanagerconfigv1alpha1.ResourceQuotaControllerConfiguration{}.OpenAPIModelName(): schema_k8sio_kube_controller_manager_config_v1alpha1_ResourceQuotaControllerConfiguration(ref),
|
||||
kubecontrollermanagerconfigv1alpha1.SAControllerConfiguration{}.OpenAPIModelName(): schema_k8sio_kube_controller_manager_config_v1alpha1_SAControllerConfiguration(ref),
|
||||
kubecontrollermanagerconfigv1alpha1.StatefulSetControllerConfiguration{}.OpenAPIModelName(): schema_k8sio_kube_controller_manager_config_v1alpha1_StatefulSetControllerConfiguration(ref),
|
||||
|
|
@ -66044,12 +66045,19 @@ func schema_k8sio_kube_controller_manager_config_v1alpha1_KubeControllerManagerC
|
|||
Ref: ref(kubecontrollermanagerconfigv1alpha1.DeviceTaintEvictionControllerConfiguration{}.OpenAPIModelName()),
|
||||
},
|
||||
},
|
||||
"ResourceClaimController": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "ResourceClaimControllerConfiguration contains elements configuring the resource claim controller.",
|
||||
Default: map[string]interface{}{},
|
||||
Ref: ref(kubecontrollermanagerconfigv1alpha1.ResourceClaimControllerConfiguration{}.OpenAPIModelName()),
|
||||
},
|
||||
},
|
||||
},
|
||||
Required: []string{"Generic", "KubeCloudShared", "AttachDetachController", "CSRSigningController", "DaemonSetController", "DeploymentController", "StatefulSetController", "DeprecatedController", "EndpointController", "EndpointSliceController", "EndpointSliceMirroringController", "EphemeralVolumeController", "GarbageCollectorController", "HPAController", "JobController", "CronJobController", "LegacySATokenCleaner", "NamespaceController", "NodeIPAMController", "NodeLifecycleController", "PersistentVolumeBinderController", "PodGCController", "ReplicaSetController", "ReplicationController", "ResourceQuotaController", "SAController", "ServiceController", "TTLAfterFinishedController", "ValidatingAdmissionPolicyStatusController", "DeviceTaintEvictionController"},
|
||||
Required: []string{"Generic", "KubeCloudShared", "AttachDetachController", "CSRSigningController", "DaemonSetController", "DeploymentController", "StatefulSetController", "DeprecatedController", "EndpointController", "EndpointSliceController", "EndpointSliceMirroringController", "EphemeralVolumeController", "GarbageCollectorController", "HPAController", "JobController", "CronJobController", "LegacySATokenCleaner", "NamespaceController", "NodeIPAMController", "NodeLifecycleController", "PersistentVolumeBinderController", "PodGCController", "ReplicaSetController", "ReplicationController", "ResourceQuotaController", "SAController", "ServiceController", "TTLAfterFinishedController", "ValidatingAdmissionPolicyStatusController", "DeviceTaintEvictionController", "ResourceClaimController"},
|
||||
},
|
||||
},
|
||||
Dependencies: []string{
|
||||
configv1alpha1.KubeCloudSharedConfiguration{}.OpenAPIModelName(), serviceconfigv1alpha1.ServiceControllerConfiguration{}.OpenAPIModelName(), controllermanagerconfigv1alpha1.GenericControllerManagerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.AttachDetachControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.CSRSigningControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.CronJobControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.DaemonSetControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.DeploymentControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.DeprecatedControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.DeviceTaintEvictionControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.EndpointControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.EndpointSliceControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.EndpointSliceMirroringControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.EphemeralVolumeControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.GarbageCollectorControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.HPAControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.JobControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.LegacySATokenCleanerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.NamespaceControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.NodeIPAMControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.NodeLifecycleControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.PersistentVolumeBinderControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.PodGCControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.ReplicaSetControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.ReplicationControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.ResourceQuotaControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.SAControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.StatefulSetControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.TTLAfterFinishedControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.ValidatingAdmissionPolicyStatusControllerConfiguration{}.OpenAPIModelName()},
|
||||
configv1alpha1.KubeCloudSharedConfiguration{}.OpenAPIModelName(), serviceconfigv1alpha1.ServiceControllerConfiguration{}.OpenAPIModelName(), controllermanagerconfigv1alpha1.GenericControllerManagerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.AttachDetachControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.CSRSigningControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.CronJobControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.DaemonSetControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.DeploymentControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.DeprecatedControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.DeviceTaintEvictionControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.EndpointControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.EndpointSliceControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.EndpointSliceMirroringControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.EphemeralVolumeControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.GarbageCollectorControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.HPAControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.JobControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.LegacySATokenCleanerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.NamespaceControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.NodeIPAMControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.NodeLifecycleControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.PersistentVolumeBinderControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.PodGCControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.ReplicaSetControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.ReplicationControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.ResourceClaimControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.ResourceQuotaControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.SAControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.StatefulSetControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.TTLAfterFinishedControllerConfiguration{}.OpenAPIModelName(), kubecontrollermanagerconfigv1alpha1.ValidatingAdmissionPolicyStatusControllerConfiguration{}.OpenAPIModelName()},
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -66390,6 +66398,28 @@ func schema_k8sio_kube_controller_manager_config_v1alpha1_ReplicationControllerC
|
|||
}
|
||||
}
|
||||
|
||||
func schema_k8sio_kube_controller_manager_config_v1alpha1_ResourceClaimControllerConfiguration(ref common.ReferenceCallback) common.OpenAPIDefinition {
|
||||
return common.OpenAPIDefinition{
|
||||
Schema: spec.Schema{
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "ResourceClaimControllerConfiguration contains elements configuring the resource claim controller.",
|
||||
Type: []string{"object"},
|
||||
Properties: map[string]spec.Schema{
|
||||
"ConcurrentSyncs": {
|
||||
SchemaProps: spec.SchemaProps{
|
||||
Description: "ConcurrentSyncs is the number of operations (deleting a pod, updating a ResourcClaim status, etc.) that will be done concurrently. Larger number = processing, but more CPU (and network) load.\n\nThe default is 50.",
|
||||
Default: 0,
|
||||
Type: []string{"integer"},
|
||||
Format: "int32",
|
||||
},
|
||||
},
|
||||
},
|
||||
Required: []string{"ConcurrentSyncs"},
|
||||
},
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
func schema_k8sio_kube_controller_manager_config_v1alpha1_ResourceQuotaControllerConfiguration(ref common.ReferenceCallback) common.OpenAPIDefinition {
|
||||
return common.OpenAPIDefinition{
|
||||
Schema: spec.Schema{
|
||||
|
|
|
|||
|
|
@ -170,6 +170,8 @@ type KubeControllerManagerConfiguration struct {
|
|||
ValidatingAdmissionPolicyStatusController ValidatingAdmissionPolicyStatusControllerConfiguration
|
||||
// DeviceTaintEvictionControllerConfiguration contains elements configuring the device taint eviction controller.
|
||||
DeviceTaintEvictionController DeviceTaintEvictionControllerConfiguration
|
||||
// ResourceClaimControllerConfiguration contains elements configuring the resource claim controller.
|
||||
ResourceClaimController ResourceClaimControllerConfiguration
|
||||
}
|
||||
|
||||
// AttachDetachControllerConfiguration contains elements describing AttachDetachController.
|
||||
|
|
@ -499,3 +501,12 @@ type DeviceTaintEvictionControllerConfiguration struct {
|
|||
// The default is 10.
|
||||
ConcurrentSyncs int32
|
||||
}
|
||||
|
||||
// ResourceClaimControllerConfiguration contains elements configuring the resource claim controller.
|
||||
type ResourceClaimControllerConfiguration struct {
|
||||
// ConcurrentSyncs is the number of operations (deleting a pod, updating a ResourcClaim status, etc.)
|
||||
// that will be done concurrently. Larger number = processing, but more CPU (and network) load.
|
||||
//
|
||||
// The default is 50.
|
||||
ConcurrentSyncs int32
|
||||
}
|
||||
|
|
|
|||
|
|
@ -338,6 +338,7 @@ func (in *KubeControllerManagerConfiguration) DeepCopyInto(out *KubeControllerMa
|
|||
out.TTLAfterFinishedController = in.TTLAfterFinishedController
|
||||
out.ValidatingAdmissionPolicyStatusController = in.ValidatingAdmissionPolicyStatusController
|
||||
out.DeviceTaintEvictionController = in.DeviceTaintEvictionController
|
||||
out.ResourceClaimController = in.ResourceClaimController
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -510,6 +511,22 @@ func (in *ReplicationControllerConfiguration) DeepCopy() *ReplicationControllerC
|
|||
return out
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *ResourceClaimControllerConfiguration) DeepCopyInto(out *ResourceClaimControllerConfiguration) {
|
||||
*out = *in
|
||||
return
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ResourceClaimControllerConfiguration.
|
||||
func (in *ResourceClaimControllerConfiguration) DeepCopy() *ResourceClaimControllerConfiguration {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(ResourceClaimControllerConfiguration)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *ResourceQuotaControllerConfiguration) DeepCopyInto(out *ResourceQuotaControllerConfiguration) {
|
||||
*out = *in
|
||||
|
|
|
|||
|
|
@ -151,6 +151,11 @@ func (in ReplicationControllerConfiguration) OpenAPIModelName() string {
|
|||
return "io.k8s.kube-controller-manager.config.v1alpha1.ReplicationControllerConfiguration"
|
||||
}
|
||||
|
||||
// OpenAPIModelName returns the OpenAPI model name for this type.
|
||||
func (in ResourceClaimControllerConfiguration) OpenAPIModelName() string {
|
||||
return "io.k8s.kube-controller-manager.config.v1alpha1.ResourceClaimControllerConfiguration"
|
||||
}
|
||||
|
||||
// OpenAPIModelName returns the OpenAPI model name for this type.
|
||||
func (in ResourceQuotaControllerConfiguration) OpenAPIModelName() string {
|
||||
return "io.k8s.kube-controller-manager.config.v1alpha1.ResourceQuotaControllerConfiguration"
|
||||
|
|
|
|||
Loading…
Reference in a new issue