Merge pull request #4395 from ihoegen/master

Add max-requests-inflight parameter
This commit is contained in:
k8s-ci-robot 2018-02-13 22:59:51 -08:00 committed by GitHub
commit 2b1ecba8e1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
11 changed files with 3415 additions and 704 deletions

File diff suppressed because one or more lines are too long

View File

@ -190,6 +190,12 @@
{
"filename": "_generated_statusdetails_v1_meta_definition.md"
},
{
"filename": "_generated_targetspec_v1alpha2_kops_definition.md"
},
{
"filename": "_generated_terraformspec_v1alpha2_kops_definition.md"
},
{
"filename": "_generated_time_v1_meta_definition.md"
},

File diff suppressed because one or more lines are too long

View File

@ -164,6 +164,16 @@ You could use the [fileAssets](https://github.com/kubernetes/kops/blob/master/do
Example policy file can be found [here]( https://raw.githubusercontent.com/kubernetes/website/master/docs/tasks/debug-application-cluster/audit-policy.yaml)
#### Max Requests Inflight
The maximum number of non-mutating requests in flight at a given time. When the server exceeds this, it rejects requests. Zero for no limit. (default 400)
```yaml
spec:
kubeAPIServer:
maxRequestsInflight: 1000
```
#### runtimeConfig
Keys and values here are translated into `--runtime-config` values for `kube-apiserver`, separated by commas.

View File

@ -39,6 +39,12 @@ func Test_KubeAPIServer_BuildFlags(t *testing.T) {
},
"--insecure-port=0 --secure-port=443",
},
{
kops.KubeAPIServerConfig{
MaxRequestsInflight: 1000,
},
"--insecure-port=0 --max-requests-inflight=1000 --secure-port=0",
},
{
kops.KubeAPIServerConfig{
InsecurePort: 8080,
@ -46,6 +52,14 @@ func Test_KubeAPIServer_BuildFlags(t *testing.T) {
},
"--insecure-port=8080 --secure-port=443",
},
{
kops.KubeAPIServerConfig{
InsecurePort: 8080,
SecurePort: 443,
MaxRequestsInflight: 1000,
},
"--insecure-port=8080 --max-requests-inflight=1000 --secure-port=443",
},
{
kops.KubeAPIServerConfig{
InsecurePort: 8080,

View File

@ -293,6 +293,8 @@ type KubeAPIServerConfig struct {
RequestheaderAllowedNames []string `json:"requestheaderAllowedNames,omitempty" flag:"requestheader-allowed-names"`
// FeatureGates is set of key=value pairs that describe feature gates for alpha/experimental features.
FeatureGates map[string]string `json:"featureGates,omitempty" flag:"feature-gates"`
// MaxRequestsInflight The maximum number of non-mutating requests in flight at a given time.
MaxRequestsInflight int32 `json:"maxRequestsInflight,omitempty" flag:"max-requests-inflight" flag-empty:"0"`
}
// KubeControllerManagerConfig is the configuration for the controller

View File

@ -293,6 +293,8 @@ type KubeAPIServerConfig struct {
RequestheaderAllowedNames []string `json:"requestheaderAllowedNames,omitempty" flag:"requestheader-allowed-names"`
// FeatureGates is set of key=value pairs that describe feature gates for alpha/experimental features.
FeatureGates map[string]string `json:"featureGates,omitempty" flag:"feature-gates"`
// MaxRequestsInflight The maximum number of non-mutating requests in flight at a given time.
MaxRequestsInflight int32 `json:"maxRequestsInflight,omitempty" flag:"max-requests-inflight" flag-empty:"0"`
}
// KubeControllerManagerConfig is the configuration for the controller

View File

@ -1804,6 +1804,7 @@ func autoConvert_v1alpha1_KubeAPIServerConfig_To_kops_KubeAPIServerConfig(in *Ku
out.RequestheaderClientCAFile = in.RequestheaderClientCAFile
out.RequestheaderAllowedNames = in.RequestheaderAllowedNames
out.FeatureGates = in.FeatureGates
out.MaxRequestsInflight = in.MaxRequestsInflight
return nil
}
@ -1866,6 +1867,7 @@ func autoConvert_kops_KubeAPIServerConfig_To_v1alpha1_KubeAPIServerConfig(in *ko
out.RequestheaderClientCAFile = in.RequestheaderClientCAFile
out.RequestheaderAllowedNames = in.RequestheaderAllowedNames
out.FeatureGates = in.FeatureGates
out.MaxRequestsInflight = in.MaxRequestsInflight
return nil
}

View File

@ -293,6 +293,8 @@ type KubeAPIServerConfig struct {
RequestheaderAllowedNames []string `json:"requestheaderAllowedNames,omitempty" flag:"requestheader-allowed-names"`
// FeatureGates is set of key=value pairs that describe feature gates for alpha/experimental features.
FeatureGates map[string]string `json:"featureGates,omitempty" flag:"feature-gates"`
// MaxRequestsInflight The maximum number of non-mutating requests in flight at a given time.
MaxRequestsInflight int32 `json:"maxRequestsInflight,omitempty" flag:"max-requests-inflight" flag-empty:"0"`
}
// KubeControllerManagerConfig is the configuration for the controller

View File

@ -2066,6 +2066,7 @@ func autoConvert_v1alpha2_KubeAPIServerConfig_To_kops_KubeAPIServerConfig(in *Ku
out.RequestheaderClientCAFile = in.RequestheaderClientCAFile
out.RequestheaderAllowedNames = in.RequestheaderAllowedNames
out.FeatureGates = in.FeatureGates
out.MaxRequestsInflight = in.MaxRequestsInflight
return nil
}
@ -2128,6 +2129,7 @@ func autoConvert_kops_KubeAPIServerConfig_To_v1alpha2_KubeAPIServerConfig(in *ko
out.RequestheaderClientCAFile = in.RequestheaderClientCAFile
out.RequestheaderAllowedNames = in.RequestheaderAllowedNames
out.FeatureGates = in.FeatureGates
out.MaxRequestsInflight = in.MaxRequestsInflight
return nil
}

File diff suppressed because it is too large Load Diff