Commit Graph

42458 Commits

Author SHA1 Message Date
Ted Yu
47ccb69907 Check error return from GetPodKey 2019-07-26 11:53:43 -07:00
Sean Sullivan
49f5b423cf Move pkg/kubectl/describe to staging 2019-07-26 10:41:49 -07:00
Kubernetes Prow Robot
614544f2cf Merge pull request #80608 from seans3/move-kubectl-bindata
Moves pkg/kubectl/util/i18n to staging
2019-07-26 09:56:38 -07:00
Janek Łukaszewicz
f9b683532a second iteration 2019-07-26 14:44:55 +02:00
Kevin Klues
9f36f1a173 Add tests for proactive init Container removal in the CPUManager static policy 2019-07-26 14:34:51 +02:00
Kevin Klues
6a7db380de Add tests for new containertMap type in the CPUManager 2019-07-26 14:34:51 +02:00
Kevin Klues
c6d9bbcb74 Proactively remove init Containers in CPUManager static policy
This patch fixes a bug in the CPUManager, whereby it doesn't honor the
"effective requests/limits" of a Pod as defined by:

    https://kubernetes.io/docs/concepts/workloads/pods/init-containers/#resources

The rule states that a Pod’s "effective request/limit" for a resource
should be the larger of:
    * The highest of any particular resource request or limit
      defined on all init Containers
    * The sum of all app Containers request/limit for a
      resource

Moreover, the rule states that:
    * The effective QoS tier is the same for init Containers
      and app containers alike

This means that the resource requests of init Containers and app
Containers should be able to overlap, such that the larger of the two
becomes the "effective resource request/limit" for the Pod. Likewise,
if a QoS tier of "Guaranteed" is determined for the Pod, then both init
Containers and app Containers should run in this tier.

In its current implementation, the CPU manager honors the effective QoS
tier for both init and app containers, but doesn't honor the "effective
request/limit" correctly.

Instead, it treats the "effective request/limit" as:
    * The sum of all init Containers plus the sum of all app
      Containers request/limit for a resource

It does this by not proactively removing the CPUs given to previous init
containers when new containers are being created. In the worst case,
this causes the CPUManager to give non-overlapping CPUs to all
containers (whether init or app) in the "Guaranteed" QoS tier before any
of the containers in the Pod actually start.

This effectively blocks these Pods from running if the total number of
CPUs being requested across init and app Containers goes beyond the
limits of the system.

This patch fixes this problem by updating the CPUManager static policy
so that it proactively removes any guaranteed CPUs it has granted to
init Containers before allocating CPUs to app containers. Since all init
container are run sequentially, it also makes sure this proactive
removal happens for previous init containers when allocating CPUs to
later ones.
2019-07-26 14:34:51 +02:00
Kubernetes Prow Robot
d5d6061c8e Merge pull request #80476 from matte21/fix-pvcs-leaks
PVC protection controller: fix PVC leaks
2019-07-26 05:31:59 -07:00
Kubernetes Prow Robot
de73f62336 Merge pull request #80495 from adityadani/update_openstorage_to_v1.0.0
pkg/volume/portworx: Update vendor for libopenstorage/openstorage to v1.0.0
2019-07-26 03:23:59 -07:00
matte21
b4fed83a4a PVC protection controller: get rid of PVC leaks
Make the PVC protection controller robust to cases where a Pod X is deleted,
then a Pod Y with the same namespaced name is created and the two events are
delivered via a single update notification. Both pods should be processed,
because X might be blocking deletion of a PVC which is not referenced by Y.
Prior to this commit only the newer pod is processed, which means that it
is possible to leak PVCs.

Also, add unit tests to reflect the change.
2019-07-26 11:17:17 +02:00
Yi Tang
8c13f9dea3 fix pv controller not find pv for pvc provisioning 2019-07-26 16:24:30 +08:00
Kubernetes Prow Robot
b72077410b Merge pull request #80520 from ethan-daocloud/patch-2
fix wrong spells in events.go
2019-07-26 00:04:00 -07:00
Sean Sullivan
70984d8385 Moves pkg/kubectl/util/i18n to staging 2019-07-25 23:09:34 -07:00
Kubernetes Prow Robot
6fc8a01544 Merge pull request #80562 from seans3/move-drain-staging
Move pkg/kubectl/drain to staging
2019-07-25 22:36:24 -07:00
Louise Daly
674ecba935 Change Socket to Node
Change Node from int in TopologyInfo to type NUMANode which is an int
2019-07-26 06:35:48 +01:00
lmdaly
c1fb5bd508 Device Plugin API change to include Topology Info in Devices 2019-07-26 05:14:14 +01:00
Kubernetes Prow Robot
b234dd06aa Merge pull request #80548 from seans3/move-kubectl-history
Move some pkg/kubectl into polymorphichelpers
2019-07-25 20:48:49 -07:00
Kubernetes Prow Robot
1a95199311 Merge pull request #80518 from jsafrane/cinder-detach-idempotent
Fix detachment of deleted volumes
2019-07-25 20:48:24 -07:00
Kubernetes Prow Robot
50a0d38e3a Merge pull request #80503 from tedyu/spread-constaints
Refactor nested loop in getTPMapMatchingSpreadConstraints
2019-07-25 20:48:11 -07:00
AllenZMC
8833e4072c fix typos in csi_attacher.go 2019-07-26 09:48:51 +08:00
Kubernetes Prow Robot
a3750501b0 Merge pull request #79983 from pohly/persistent-and-ephemeral-csi-volumes
persistent and ephemeral csi volumes
2019-07-25 16:01:54 -07:00
Kubernetes Prow Robot
a172e197b1 Merge pull request #77355 from apelisse/test-new-protoc
Use new reverse protobuf marshalling
2019-07-25 16:01:14 -07:00
Andrew Sy Kim
c5ccc38362 document API guarentees and deprecation policies for cloud config files
Signed-off-by: Andrew Sy Kim <kiman@vmware.com>
2019-07-25 17:45:19 -04:00
Aditya Dani
ab72c09937 Update pkg/volume/portworx OWNERs 2019-07-25 14:39:24 -07:00
Kubernetes Prow Robot
69a34f6a6f Merge pull request #80361 from wojtek-t/remove_get_reference
Remove unneeded directory
2019-07-25 14:34:37 -07:00
Kubernetes Prow Robot
d793279dee Merge pull request #80094 from ZP-AlwaysWin/dev03
Fix golint failure in pkg/quota/v1/evaluator/core
2019-07-25 14:34:24 -07:00
Kubernetes Prow Robot
0e3b593ded Merge pull request #79851 from jparklab/master
Fix nil pointer dereference error in volume_stat_calculator
2019-07-25 14:33:58 -07:00
Kubernetes Prow Robot
7fd8537564 Merge pull request #79062 from Huang-Wei/eps-preemption
Even Pods Spread - 4. Preemption Support
2019-07-25 14:33:45 -07:00
Antoine Pelisse
6568325ca2 Regenerate 2019-07-25 11:54:00 -07:00
wojtekt
467f5e96ee Fix some golint failures 2019-07-25 20:38:28 +02:00
Sean Sullivan
775b670e8b Move some pkg/kubectl into polymorphichelpers 2019-07-25 11:36:04 -07:00
wojtekt
117a0e525d Unify secret and configmap triggers 2019-07-25 20:35:20 +02:00
Kubernetes Prow Robot
bf2dd03083 Merge pull request #80318 from davidxia/fix-err-caps
cleanup: fix some log and error capitalizations
2019-07-25 10:41:28 -07:00
Dan Winship
bf077b19d4 hostport: Don't masquerade localhost-to-localhost traffic 2019-07-25 13:34:14 -04:00
Sean Sullivan
eaea71cf84 Move pkg/kubectl/drain to staging 2019-07-25 10:23:32 -07:00
Patrick Ohly
555ff7ef10 CSI: allow drivers that can handle persistent and ephemeral volumes
The conceptual change is that the mode in which a volume gets handled
is derived from it's spec, not from the ability of the driver. In
practice, that is already how the code worked because it didn't
actually look at CSIDriver.Spec.Mode at all.

Therefore the code change itself is mostly just renaming "driver mode"
to "volume mode". In some places (CanDeviceMount, CanAttach) the
feature check that was used elsewhere seemed to be missing. Now their
code path for ephemeral volumes are also only entered if that feature
is enabled.

The sanity check whether a CSI driver is being used correctly still
needs to be implemented.

Related-to: https://github.com/kubernetes/kubernetes/issues/79624
2019-07-25 16:45:46 +02:00
Kubernetes Prow Robot
81684586db Merge pull request #80558 from seans3/move-apply-util
Move pkg/kubectl/apply.go to staging
2019-07-25 07:36:34 -07:00
Kubernetes Prow Robot
16a820b906 Merge pull request #80556 from AllenZMC/patch-3
fix typos in pv_controller.go
2019-07-25 07:36:21 -07:00
Kubernetes Prow Robot
5153e242a7 Merge pull request #80554 from seans3/move-kubectl-apps
Move pkg/kubectl/apps to staging
2019-07-25 07:36:08 -07:00
Kubernetes Prow Robot
7aa5f9727b Merge pull request #80347 from humblec/metrics
Remove unwanted string converstion in metrics errors
2019-07-25 07:35:55 -07:00
Ted Yu
89818d8d09 Refactor nested loop in getTPMapMatchingSpreadConstraints 2019-07-25 07:15:14 -07:00
Aldo Culquicondor
0e35ac8f1e Update TODO
Signed-off-by: Aldo Culquicondor <acondor@google.com>
2019-07-25 10:09:42 -04:00
Rostislav M. Georgiev
8157c4c4a8 Remove unused package //pkg/util/normalizer
Signed-off-by: Rostislav M. Georgiev <rostislavg@vmware.com>
2019-07-25 15:36:00 +03:00
Aldo Culquicondor
e703226522 Optimize Schedule by querying nodes only when needed.
Signed-off-by: Aldo Culquicondor <acondor@google.com>
2019-07-25 08:24:05 -04:00
Kevin Klues
7eccc71c9e Rename 'preferred' TopologyManager policy to 'best-effort' 2019-07-25 10:44:36 +02:00
Jan Safranek
cdcd2e2821 Report error when iscsiadm fails during detach
Kubernetes should retry detaching iSCSI volumes on error. In addition, it
should not report an error when detaching a disk while the disk is already
detached.
2019-07-25 10:10:01 +02:00
Kubernetes Prow Robot
20106560f7 Merge pull request #79425 from johscheuer/fix-networkpolicy-typo
Fix typo in network policy ingress rule
2019-07-24 21:19:51 -07:00
Sean Sullivan
309de42878 Move pkg/kubectl/apply.go to staging 2019-07-24 20:40:25 -07:00
AllenZMC
852040c036 fix typos in pv_controller.go
make code kinda more readable
2019-07-25 11:28:19 +08:00
Sean Sullivan
1b52c6180b Move pkg/kubectl/apps to staging 2019-07-24 20:10:31 -07:00