Commit Graph

917 Commits

Author SHA1 Message Date
Paco Xu
03a15fa65d Revert "[FG:InPlacePodVerticalScaling] Graduate to Beta" 2024-11-20 14:55:29 +08:00
Tim Allclair
8342d39956 Equate CPU limits below the minimum effective limit (10m) 2024-11-12 17:23:17 -08:00
Kubernetes Prow Robot
79e5584257 Merge pull request #128682 from tallclair/ippr-beta
[FG:InPlacePodVerticalScaling] Graduate to Beta
2024-11-12 19:00:46 +00:00
Tim Allclair
25cf2a2aac Allow adding limits 2024-11-11 12:04:36 -08:00
Tim Allclair
caedccf0e4 Allow resize when pod limits aren't set 2024-11-11 12:04:36 -08:00
Tim Allclair
479b300227 Fix unit tests 2024-11-09 14:29:02 -08:00
Kubernetes Prow Robot
591c75e40b Merge pull request #128694 from tallclair/revert-127300-error-propagation
Revert "[FG:InPlacePodVerticalScaling] kubelet: Propagate error in doPodResizeAction() to the caller"
2024-11-08 19:14:43 +00:00
Tim Allclair
1d822f1dc8 Fix linter errors 2024-11-08 06:48:50 -08:00
Kubernetes Prow Robot
c25f5eefe4 Merge pull request #128407 from ndixita/pod-level-resources
[PodLevelResources] Pod Level Resources Feature Alpha
2024-11-08 07:10:50 +00:00
Tim Allclair
bf8354d460 Revert "[FG:InPlacePodVerticalScaling] kubelet: Propagate error in doPodResizeAction() to the caller" 2024-11-07 22:43:59 -08:00
Kubernetes Prow Robot
0fff5bbe7d Merge pull request #128680 from tallclair/min-cpu
[FG:InPlacePodVerticalScaling] Handle edge cases around CPU MinShares
2024-11-08 05:24:51 +00:00
ndixita
5ea57fb3b4 cgroup configuration changes:
1. Pod cgrooup configured to use resources from pod spec if feature is enabled and resources are set at pod-level
2. Container cgroup limits defaulted to pod-level limits is container limits are not set
2024-11-08 03:00:54 +00:00
Kubernetes Prow Robot
210f129bb0 Merge pull request #128676 from vivzbansal/sidecar-3
Refactor: Move IsRestartableInitContainer to common utility package
2024-11-08 02:21:50 +00:00
Kubernetes Prow Robot
b35bbecbc5 Merge pull request #128506 from kolyshkin/cgroups-nit
kubelet/kuberuntime: switch to runc/libct
2024-11-08 02:21:34 +00:00
Kubernetes Prow Robot
30052523d7 Merge pull request #127300 from hshiina/error-propagation
[FG:InPlacePodVerticalScaling] kubelet: Propagate error in doPodResizeAction() to the caller
2024-11-08 02:20:57 +00:00
Tim Allclair
5a3a40cd19 Handle resize edge cases around min CPU shares 2024-11-07 17:02:25 -08:00
Kubernetes Prow Robot
8504758a2e Merge pull request #125757 from Nordix/esotsal/125205
[FG:InPlacePodVerticalScaling] Fix backoff problem when quickly reverting resize patch
2024-11-07 23:32:42 +00:00
vivzbansal
763e810fb5 refactor code to add sidecar container support in IPPR 2024-11-07 21:20:48 +00:00
Kir Kolyshkin
19477b7eed kubelet/kuberuntime: use sync.OnceValue
This was added to Go 1.21, and makes the code simpler.

(Best reviewed ignoring changes in amount of whitespace).

Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
2024-11-07 13:11:49 -08:00
Kir Kolyshkin
3a1b0f2864 kubelet/kuberuntime: switch to runc/libct
runc/libcontainer/cgroups.ParseCgroupFile is a universal function; for
cgroup v2 it returns path to unified in a map with "" as a key.

Let's use it here, dropping cgroups dependency entirely.

Amends commit e86d02b60c.

Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
2024-11-07 13:04:56 -08:00
Kubernetes Prow Robot
25101d33bc Merge pull request #128518 from tallclair/pleg-watch-conditions
[FG:InPlacePodVerticalScaling] PLEG watch conditions: rapid polling for expected changes
2024-11-07 19:45:01 +00:00
Sotiris Salloumis
68fcc9cf8a Fix slow reconcile when quickly reverting resize patch 2024-11-07 19:51:47 +01:00
Kubernetes Prow Robot
c462d4c8e5 Merge pull request #126096 from utam0k/support-disabling-oom-group-kill
kubelet: new kubelet config option for disabling group oom kill
2024-11-07 06:29:36 +00:00
utam0k
4f909c14a0 kubelet: new kubelet config option for disabling group oom kill
Signed-off-by: utam0k <k0ma@utam0k.jp>
2024-11-07 12:03:04 +09:00
Tim Allclair
7fce6f2317 More comments around PLEG WatchConditions 2024-11-06 11:05:24 -08:00
Tim Allclair
da9c2c553b Set pod watch conditions for resize 2024-11-06 11:05:24 -08:00
Kubernetes Prow Robot
98b4ee6bfa Merge pull request #126525 from dshebib/addSidecarE2EImgTest
Restart sidecar container when the image has changed
2024-11-06 00:35:35 +00:00
Hironori Shiina
5562cb165b kubelet: Propagate error in doPodResizeAction() to the caller
This fix makes doPodResizeAction() return the result instead of setting
an error to the `result` argument, which should have been passed as a
pointer, so that the error is propagated to the caller. This fix also
makes the usage of PodSyncResult more consistent with other operations
like starting and killing a container.
2024-11-05 16:37:29 +01:00
Kubernetes Prow Robot
a8e1f41131 Merge pull request #124216 from iholder101/in-pod-vertical-scaling/update-cgroup-systemd-instead-of-cgroupfs
[FG:InPlacePodVerticalScaling] Handle systemd cgroup driver by using libcontainer for updating pod cgroup values
2024-11-04 20:17:29 +00:00
Davanum Srinivas
e86d02b60c Copy ParseCgroupFileUnified and Drop rest of containerd/cgroups
Signed-off-by: Davanum Srinivas <davanum@gmail.com>
2024-10-31 13:42:39 -04:00
Itamar Holder
f21473b924 Set pod-level CPUPeriod only if CPUQuota is changed
Signed-off-by: Itamar Holder <iholder@redhat.com>
2024-10-30 14:21:35 +02:00
Itamar Holder
c792c30b6a Refactor: remove no longer needed resourceName parameter
Signed-off-by: Itamar Holder <iholder@redhat.com>
2024-10-30 13:58:38 +02:00
Kubernetes Prow Robot
6737352b03 Merge pull request #125708 from hshiina/dopodresizeaction-error
[FG:InPlacePodVerticalScaling] Fix order of resizing pod cgroups in doPodResizeAction()
2024-10-30 01:21:25 +00:00
Kubernetes Prow Robot
b3cf9c6e5c Merge pull request #128269 from tallclair/allocated
[FG:InPlacePodVerticalScaling] Rework handling of allocated resources
2024-10-25 23:24:52 +01:00
AxeZhan
2ffb568540 rename functions 2024-10-25 12:53:24 +08:00
Tim Allclair
d1f1bf200c Add more comments 2024-10-24 15:51:19 -07:00
Tim Allclair
321eff34f7 Rework allocated resources handling 2024-10-24 09:27:40 -07:00
Daniel Shebib
43d527ad68 add restart on definition change 2024-10-18 15:35:06 -05:00
Daniel Shebib
3710d6f570 reset kuberuntime_container 2024-10-18 15:34:44 -05:00
Kubernetes Prow Robot
141951cd6b Merge pull request #126420 from hoskeri/fix-container-succeeded-check-status
kuberuntime_manager: fix container success check.
2024-10-17 20:31:04 +01:00
Kubernetes Prow Robot
d1e03f3a77 Merge pull request #127195 from yaojunyu/fix-pod-alway-restart-open-envetedpleg
EventedPLEG: Set Timestamp in PodStatus for Generic PLEG more accurate
2024-10-14 23:36:20 +01:00
Daniel Shebib
51883d5821 sidecar containers restart on definition change 2024-10-13 01:21:57 -05:00
Kubernetes Prow Robot
36122d5a9b Merge pull request #125103 from hjet/kuberuntime-testcov
[FG:InPlacePodVerticalScaling] Expand coverage for TestGenerateLinuxContainerResources
2024-10-09 01:58:22 +01:00
Kubernetes Prow Robot
a7fcc89ac0 Merge pull request #125936 from sivchari/use-ptr
use utils/ptr package instead of utils/pointer
2024-10-07 01:02:04 +01:00
sivchari
4eab3cca0a use utils/ptr package instead of utils/pointer
Signed-off-by: sivchari <shibuuuu5@gmail.com>
2024-10-03 11:33:12 +09:00
Kubernetes Prow Robot
e34f7f4d80 Merge pull request #127671 from mmorel-35/testify/error-contains
fix: use `ErrorContains(t, err` instead of `Contains(t, err.Error()`
2024-09-28 19:18:01 +01:00
Matthieu MOREL
f736cca0e5 fix: enable expected-actual rule from testifylint in module k8s.io/kubernetes
Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
2024-09-27 07:56:31 +02:00
Matthieu MOREL
f777addb05 fix: use ErrorContains(t, err instead of Contains(t, err.Error()
Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
2024-09-26 22:22:20 +02:00
Matthieu MOREL
27b98be303 fix: enable nil-compare and error-nil rules from testifylint in module k8s.io/kubernetes
Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
2024-09-25 06:02:47 +02:00
Davanum Srinivas
02c6df0436 Treat Timestamp as nanoseconds which response by PodSandboxStatus(e.g. CRI-O) and fix zero Timestamp without setting (e.g. containerd) change to now. 2024-09-22 15:59:43 +08:00