Commit Graph

40526 Commits

Author SHA1 Message Date
Haowei Cai
c9bbd8532f generalize lease controller 2020-10-22 11:58:59 -07:00
Haowei Cai
c70e3649e1 move node lease controller to component-helpers 2020-10-22 11:58:58 -07:00
Amim Knabben
8ed6ca58bc Replacing factory tests with scheduler.New and options 2020-10-22 11:43:28 -04:00
chenyw1990
009d46f834 write checkpoint only when allocated devices updated. 2020-10-22 22:45:04 +08:00
qingsenLi
30bfa7d078 remove unused const failedExpiration 2020-10-22 18:57:36 +08:00
weiwei
b19a115f42 If we set SelectPolicy MinPolicySelect on scaleUp behavior or scaleDown behavior,Horizontal Pod Autoscaler doesn`t automatically scale the number of pods correctly
Signed-off-by: weiwei <weiwei@tenxcloud.com>
2020-10-22 18:00:49 +08:00
qingsenLi
9ad39c9eda format incorrectAddresses in klog 2020-10-22 17:26:29 +08:00
Pingan2017
a1063c924b fix loop bug for verify attached volume 2020-10-22 13:58:40 +08:00
Masashi Honma
c6d2808ad6 ipset: Address a TODO, add test for TestEntry() with IPv6 address
This TODO was introduced by
commit 45ad69765e "wrapper ipset util".

Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
2020-10-22 08:20:24 +09:00
Aldo Culquicondor
15d2ab1615 Fix labels for spreading benchmark
Nodes where being created with beta zone label, whereas the service was using stable.

Change-Id: I08ba1b6c083217759524236bde3888e527b4a44f
2020-10-21 15:51:44 -04:00
Arjun Naik
0fec7b0f7e Added functionality and API for pod autoscaling based on container resources
Signed-off-by: Arjun Naik <anaik@redhat.com>
2020-10-21 21:10:05 +02:00
Kubernetes Prow Robot
7509c4eb47 Merge pull request #94381 from mgugino-upstream-stage/eviction-disrupted-pods
Allow deletion of unhealthy pods if enough healthy
2020-10-21 02:24:20 -07:00
Kubernetes Prow Robot
a8a779133a Merge pull request #95502 from suramrit/lintCorrection
Fix golint errors by adding definition comments for pkg/apis/apiserverinternal
2020-10-20 12:56:33 -07:00
Kubernetes Prow Robot
163b23f163 Merge pull request #95529 from cici37/cleanup
Add back openapi gen for generic types and clean up doc.go
2020-10-20 11:22:34 -07:00
Kubernetes Prow Robot
0900340b98 Merge pull request #95505 from wawa0210/fix-94490
Action Required: Windows hyper-v container featuregate is deprecated in 1.20 and will be removed in 1.21
2020-10-20 11:22:20 -07:00
Michael Gugino
717be0cd44 Allow deletion of unhealthy pods if enough healthy
Currently, if you have a PDB with 0 disruptions
available and you attempt to evict a non-healthy
pod, the eviction request will always fail.  This
is because the eviction API does not currently
take in to account that the pod you are removing
is the unhealthy one.

This commit accounts for trying to evict an
unhealthy pod as long as there are enough healthy
pods to satisfy the PDB's requirements.  To
protect against race conditions, a ResourceVersion
constraint is enforced.  This will ensure that
the target pod does not go healthy and allow
any race condition to occur which might disrupt
too many pods at once.

This commit also eliminates superfluous class to
DeepCopy for the deleteOptions struct.
2020-10-20 12:59:23 -04:00
Kubernetes Prow Robot
3fe372c3da Merge pull request #95631 from alculquicondor/enable-default-spreading
Graduate DefaultPodTopologySpread to beta
2020-10-20 07:58:09 -07:00
wawa0210
e7f319870a Warn that hyper-v featuregate will be deprecated in 1.20 and will be removed in 1.21 2020-10-20 08:37:55 +08:00
Kubernetes Prow Robot
3175b59ac2 Merge pull request #94489 from ialidzhikov/fix/volume-expand
Do not assume storageclass is still in-tree after csi migration
2020-10-19 15:08:07 -07:00
cici37
95acec5a3b Move client_builder to k8s.io/controller-manager 2020-10-19 14:48:22 -07:00
Aldo Culquicondor
87c8349bdc Graduate DefaultPodTopologySpread to beta
And set to enabled by default

Change-Id: Ie4cc4758c52492924cb0663450f2747908cb5882
2020-10-19 16:58:09 -04:00
Kubernetes Prow Robot
c71519e53d Merge pull request #95267 from twosigma/betahostnamefqdn
SetHostnameAsFQDN will be beta in v1.20, enable feature gate by default.
2020-10-19 13:26:14 -07:00
Surya Seetharaman
477b14b3c4 Kube-proxy: Perf-fix: Shrink INPUT chain
In #56164, we had split the reject rules for non-ep existing services
into KUBE-EXTERNAL-SERVICES chain in order to avoid calling KUBE-SERVICES
from INPUT. However in #74394 KUBE-SERVICES was re-added into INPUT.

As noted in #56164, kernel is sensitive to the size of INPUT chain. This
patch refrains from calling the KUBE-SERVICES chain from INPUT and FORWARD,
instead adds the lb reject rule to the KUBE-EXTERNAL-SERVICES chain which will be
called from INPUT and FORWARD.
2020-10-19 11:26:04 +02:00
jornshen
b6b462beba Fix flaky unit test Test_Run_Positive_VolumeMountControllerAttachEnabledRace data race
ref: https://github.com/kubernetes/kubernetes/issues/94568
2020-10-19 16:29:15 +08:00
Antonio Ojea
e3c1777f7d conntrack log delete operations 2020-10-19 10:01:58 +02:00
Antonio Ojea
880baa9f6f kube-proxy: log stale services operations 2020-10-19 09:35:34 +02:00
Masashi Honma
81ed48a471 test: Fix using deprecated default cluster IPs
The unit test for controlplane produces a warning caused by using deprecated default cluster IPs.

make test WHAT=./pkg/controlplane GOFLAGS=-v
W1015 07:42:59.203836  111754 services.go:37] No CIDR for service cluster IPs specified. Default value which was 10.0.0.0/24 is deprecated and will be removed in future releases. Please specify it using --service-cluster-ip-range on kube-apiserver.

This warning appears in six tests, TestValidOpenAPISpec, TestLegacyRestStorageStrategies, TestCertificatesRestStorageStrategies, TestVersion, TestAPIVersionOfDiscoveryEndpoints, TestStorageVersionHashes and TestStorageVersionHashEqualities.

This patch fixes the warning by passing ServiceIPRange.

Signed-off-by: Masashi Honma <masashi.honma@gmail.com>
2020-10-17 07:38:10 +09:00
Sergey Kanzhelev
6c2556c5c4 The function shouldRecordEvent will panic when the value of input object is nil 2020-10-16 21:13:49 +00:00
cici37
0d2002229f Add back openapi gen for generic types and clean up doc.go 2020-10-16 10:54:15 -07:00
Kubernetes Prow Robot
5fc80692c5 Merge pull request #94591 from Lion-Wei/lb-fw
Fix failing test "Services should only allow access from service loadbalancer source ranges"
2020-10-16 09:01:26 -07:00
Lion-Wei
1f7ea16560 kube-proxy ensure KUBE-MARK-DROP exist but not modify their rules 2020-10-16 14:52:07 +08:00
Shintaro Murakami
acc970399d Remove redundant variable
The variable firstUnhealthyOrdinal is redundant because replicas and condemned are already sorted in ascending order.
2020-10-16 09:53:34 +09:00
Kubernetes Prow Robot
78828078ca Merge pull request #95566 from danwinship/sctp-ga
Move SCTP to GA
2020-10-15 15:35:25 -07:00
Kubernetes Prow Robot
fd5d61060a Merge pull request #95561 from deads2k/container-status
kubelet container status calculation doesn't handle suddenly missing data properly
2020-10-15 13:49:26 -07:00
Kubernetes Prow Robot
fbe806ef9e Merge pull request #95448 from alculquicondor/policy-spread
Map SelectorSpreadPriority to PodTopologySpread plugin
2020-10-15 12:55:25 -07:00
David Eads
ff7d1444f0 kubelet container status calculation doesn't handle suddenly missing data properly 2020-10-15 12:26:16 -04:00
Kubernetes Prow Robot
d970c18ab8 Merge pull request #95451 from mkumatag/fix_fc
Fix fcpath
2020-10-15 07:10:39 -07:00
Dan Winship
3a110546ed Move SCTP to GA 2020-10-15 08:56:33 -04:00
Kubernetes Prow Robot
56833a63c9 Merge pull request #95560 from josephburnett/ignoredeleted
Ignore deleted pods.
2020-10-15 02:54:24 -07:00
Kubernetes Prow Robot
978233775e Merge pull request #94992 from lala123912/gxf
fix pkg/volume/util static checks
2020-10-15 00:44:24 -07:00
Kenichi Omichi
c0795782e0 Move dirExists() to kubelet_test
dirExists() is called from kubelet_test only.
This moves the function to kubelet_test for cleanup.
2020-10-14 17:50:00 +00:00
Aldo Culquicondor
95dd99905f Map SelectorSpreadPriority to PodTopologySpread plugin
when DefaultPodTopologySpread feature is enabled

If SelectorSpreadPriority is in use, PodTopologySpread gets inevitably enabled.
When only EvenPodsSpreadPriority is in use, PodTopologySpread is configured without system defaults.

Change-Id: I2389a585cd8ad0bd35b0d2acae1665cd46908b3e
2020-10-14 13:45:26 -04:00
Manjunath A Kumatagi
4a75c7ef1e Fix fcpath 2020-10-14 21:15:22 +05:30
Kubernetes Prow Robot
b2de4a6159 Merge pull request #95539 from soulxu/issue_95442
Reorder default Filter plugins to have UnschedulableAndUnresolvable f…
2020-10-14 08:09:54 -07:00
Joseph Burnett
1ccaaa768d Ignore deleted pods.
When a pod is deleted, it is given a deletion timestamp. However the
pod might still run for some time during graceful shutdown. During
this time it might still produce CPU utilization metrics and be in a
Running phase.

Currently the HPA replica calculator attempts to ignore deleted pods
by skipping over them. However by not adding them to the ignoredPods
set, their metrics are not removed from the average utilization
calculation. This allows pods in the process of shutting down to drag
down the recommmended number of replicas by producing near 0%
utilization metrics.

In fact the ignoredPods set is misnomer. Those pods are not fully
ignored. When the replica calculator recommends to scale up, 0%
utilization metrics are filled in for those pods to limit the scale
up. This prevents overscaling when pods take some time to startup. In
fact, there should be 4 sets considered (readyPods, unreadyPods,
missingPods, ignoredPods) not just 3.

This change renames ignoredPods as unreadyPods and leaves the scaleup
limiting semantics. Another set (actually) ignoredPods is added to
which delete pods are added instead of being skipped during
grouping. Both ignoredPods and unreadyPods have their metrics removed
from consideration. But only unreadyPods have 0% utilization metrics
filled in upon scaleup.
2020-10-14 16:45:06 +02:00
He Jie Xu
6e55b88725 Reorder default Filter plugins to have UnschedulableAndUnresolvable first 2020-10-14 09:40:51 +00:00
Kubernetes Prow Robot
8647eece9c Merge pull request #95113 from Git-Jiro/lint_ttlcontroller
Lint ttl_controller
2020-10-13 22:51:53 -07:00
Kenichi Omichi
11b1307b25 Add unit tests for dockershim/exec.go
When trying to fix a dockershim issue, there were not any unit tests
for dockershim/exec.go and it was difficult to add the corresponding
unit test for the bug.
This adds the unit tests for avoiding such situation in the future.
2020-10-14 02:04:43 +00:00
Kubernetes Prow Robot
6268e6f990 Merge pull request #95069 from farah/split-scheduler
Move scheduler interface to pkg/scheduler/framework
2020-10-13 14:23:54 -07:00
Kubernetes Prow Robot
ea896a2e64 Merge pull request #95224 from Git-Jiro/lint_endpoint
Fix lint errors in pkg/contoller/endpoint
2020-10-13 12:06:27 -07:00