Commit Graph

9282 Commits

Author SHA1 Message Date
Mahmoud Atwa 24ef1f4319 Cluster Autoscaler: Disable printf analyzer & update go version 2025-05-13 16:27:08 +00:00
elmiko e03f7068d5 update clusterapi readme with node group limit info
this change is adding an extra note to the readme to help users
understand how the autoscaler works when it is outside the minimum and
mamximum limits. it is being added to help inform users and also because
the readme is embedded in clusterapi documentation.
2025-05-13 10:45:35 -04:00
Kubernetes Prow Robot 6b55dc9009
Merge pull request #8120 from kubernetes/raywainman-patch-4
Update VPA release instructions with correct tag command
2025-05-12 22:35:16 -07:00
Kubernetes Prow Robot 8d45fcd183
Merge pull request #8122 from toVersus/chore/vpa-inplace-metrics-name-typo
Fix typos in the metric name for VPA In-Place update
2025-05-12 21:41:15 -07:00
Tsubasa Nagasawa 8e8979c91a Fix typos in the metric name for VPA In-Place update
Signed-off-by: Tsubasa Nagasawa <toversus2357@gmail.com>
2025-05-13 08:53:04 +09:00
Daniel Kłobuszewski baa6c52c47 Bump go version in builder 2025-05-12 22:27:03 +00:00
Daniel Kłobuszewski e42d50d191 Update Kubernetes deps to 1.33.0-beta.0 2025-05-12 22:27:03 +00:00
Ray Wainman 6076fb36f1
Update VPA release instructions with correct tag command 2025-05-12 17:49:44 -04:00
Ray Wainman a1ab8bc55f
Update VPA version.go to 1.5.0 for release 2025-05-12 17:25:21 -04:00
Kubernetes Prow Robot 2b33c4c790
Merge pull request #8115 from maxcao13/kubernetes-in-place-updates
VPA: Implement in-place updates support
2025-05-12 11:27:16 -07:00
Kubernetes Prow Robot 2ca75135fb
Merge pull request #7694 from mtrqq/bug/clean-instance-templates
Fix memory leak while fetching GCE instance templates.
2025-05-12 04:13:16 -07:00
Kubernetes Prow Robot 2937e9c3da
Merge pull request #8117 from jlamillan/jlamillan/oci_sdk_65.90
Upgrade OCI provider SDK to v65.90.0. Required for Go 1.24.
2025-05-12 03:45:15 -07:00
jesse.millan 3fd510bb5a
Upgrade OCI provider SDK to v65.90.0. Required for Go 1.24. 2025-05-10 22:57:16 -07:00
Max Cao 3039f3cc92
VPA: upgrade InPlacePodVerticalScaling internal logic to k8s 1.33
Signed-off-by: Max Cao <macao@redhat.com>
2025-05-09 13:38:51 -07:00
Max Cao 66b4c962d6
VPA: fix InPlaceOrRecreate feature gate version
Signed-off-by: Max Cao <macao@redhat.com>
2025-05-09 13:38:51 -07:00
Max Cao 2a3764d007
VPA: use sha256 digest for local kind image
Signed-off-by: Max Cao <macao@redhat.com>
2025-05-09 13:38:47 -07:00
Kubernetes Prow Robot ff5595519e
Merge pull request #8114 from d-honeybadger/priority-expander-docs-corrections
correct documentation on cluster-autoscaler priority expander configmap
2025-05-09 08:29:33 -07:00
Kubernetes Prow Robot a65fdb4031
Merge pull request #8081 from raywainman/vpa-release-instructions
VPA - Update release instructions for automatically built images
2025-05-09 07:21:16 -07:00
Ray Wainman 7bbb443a0f
Update vertical-pod-autoscaler/RELEASE.md
Co-authored-by: Adrian Moisey <adrian@changeover.za.net>
2025-05-09 10:02:53 -04:00
dkomsa b7fa3cd01d correct and clarify documentation on cluster-autoscaler priority expander configmap
Signed-off-by: dkomsa <dkomsa@digitalocean.com>
2025-05-09 09:27:30 -04:00
Max Cao 4f18830d51
VPA: refactor e2e test ginkgo wrapper functions
This commit refactors the VPA e2e test ginkgo wrappers so that they we can easily supply ginkgo decorators.
This allows us to add ginkgo v2 labels to suites so that later we can run tests that only run FG tests.
For now, this would only be useful for FG:InPlaceOrRecreate

Signed-off-by: Max Cao <macao@redhat.com>
2025-05-08 14:40:37 -07:00
Max Cao 087e946e1a
VPA: add InPlaceOrRecreate e2e tests
Signed-off-by: Max Cao <macao@redhat.com>
2025-05-08 14:40:37 -07:00
Max Cao 8a9a4b8c96
VPA: bump up overall e2e test timeout
Signed-off-by: Max Cao <macao@redhat.com>
2025-05-08 14:39:38 -07:00
Omer Aplatony 8806d180c2
Update features.md
Co-authored-by: Max Cao <macao@redhat.com>
2025-05-08 14:39:38 -07:00
Omer Aplatony 036a482bc9
Adjust comments
Signed-off-by: Omer Aplatony <omerap12@gmail.com>
2025-05-08 14:39:38 -07:00
Omer Aplatony 94d55a5f7b
Update vertical-pod-autoscaler/docs/features.md
Co-authored-by: Adrian Moisey <adrian@changeover.za.net>
2025-05-08 14:39:38 -07:00
Omer Aplatony 11e7560180
Add docs for in-place updates
Signed-off-by: Omer Aplatony <omerap12@gmail.com>
2025-05-08 14:39:37 -07:00
Max Cao c5eecc6c4c
address raywainman and omerap12 comments
Signed-off-by: Max Cao <macao@redhat.com>
2025-05-08 14:39:37 -07:00
Max Cao 9eac8fc5c5
VPA: refactor in-place and eviction logic
This commit refactors inplace logic outside of the pods eviction restriction and separates them into their own files.
Also this commit adds PatchResourceTarget to calculators to allow them to explictly specify to the caller which
resource/subresource they should be patched to. This commit also creates a utils subpackage in order to prevent
dependency cycles in the unit tests, and adds various unit tests. Lastly, this commit adds a rateLimiter specifically
for limiting inPlaceResize API calls.

Signed-off-by: Max Cao <macao@redhat.com>
2025-05-08 14:39:37 -07:00
Max Cao 15883dce79
VPA: Update vpa-rbac.yaml for allowing in place resize requests
Signed-off-by: Max Cao <macao@redhat.com>
2025-05-08 14:39:37 -07:00
Max Cao d6376c48f6
VPA: fixup vpa-process-yaml.sh script
The script needs to also check if the yaml input is a Deployment, and no longer needs to check for vpa-component names.

Signed-off-by: Max Cao <macao@redhat.com>
2025-05-08 14:39:37 -07:00
Max Cao 7df0c2fcbc
VPA: Updater in-place updates unit tests
Signed-off-by: Max Cao <macao@redhat.com>
2025-05-08 14:39:37 -07:00
Max Cao 6ebeb83f1d
VPA: Allow updater to actuate InPlaceOrRecreate updates
Introduces large changes in the updater component to allow InPlaceOrRecreate mode.
If the feature gate is enabled and the VPA update mode is InPlaceOrRecreate, the updater will attempt an in place update by first
checking a number of preconditions before actuation (e.g., if the pod's qosClass would be changed, whether we are already in-place resizing,
whether an in-place update may potentially violate disruption(previously eviction) tolerance, etc.).
After the preconditions are validated, we send an update signal to the InPlacePodVerticalScaling API with the recommendation, which may or may not fail.
Failures are handled in subsequent updater loops.

As for implementation details, patchCalculators have been re-used from the admission-controllers code for the updater in order to calculate recommendations for the updater to actuate.
InPlace logic has been mostly stuffed in the eviction package for now because of similarities and ease (user-initated API calls eviction vs. in-place; both cause disruption).
It may or may not be useful to refactor this later.

Signed-off-by: Max Cao <macao@redhat.com>
2025-05-08 14:38:54 -07:00
John Kyros 2af23c885b
VPA: Add metrics gauges for in-place updates
We might want to add a few more that are combined disruption counters,
e.g. in-place + eviction totals, but for now just add some separate
counters to keep track of what in-place updates are doing.
2025-05-08 14:38:36 -07:00
Max Cao b37a3eb264
VPA: Allow admission-controller to validate in-place spec
Only allow VPA objects with InPlaceOrRecreate update mode to be created if InPlaceOrRecreate feature gate is enabled. If a VPA object already exists with this mode on, and the feature gate is disabled, this prevents further objects to be created with InPlaceOrRecreate, but this does not prevent the existing InPlaceOrRecreate VPA objects with from being modified.

Signed-off-by: Max Cao <macao@redhat.com>
2025-05-08 14:38:36 -07:00
Max Cao eb153611ff
VPA: Allow deploying InPlaceOrRecreate in local e2e and ci
Allows you to specify an env var FEATURE_GATES which adds feature gates to all vpa components during vpa-up and e2e tests.
Also allows local e2e tests to run kind with a new kind-config file which enables KEP-1287 InPlacePodVerticalScaling feature gate.
Separates the admission-controller service into a separate deploy manifest.

Signed-off-by: Max Cao <macao@redhat.com>
2025-05-08 14:38:35 -07:00
Max Cao 6f86a9852f
VPA: Introduce VPA feature gates; add InPlaceOrRecreate feature gate
Signed-off-by: Max Cao <macao@redhat.com>
2025-05-08 14:37:29 -07:00
John Kyros 770b76797f
VPA: Add UpdateModeInPlaceOrRecreate to types
This adds the UpdateModeInPlaceOrRecreate mode to the types so we
can use it.

Signed-off-by: Max Cao <macao@redhat.com>
2025-05-08 14:37:29 -07:00
Kubernetes Prow Robot b98a5ffc16
Merge pull request #8061 from Uladzislau97/dra-provider
Move DRA provider to autoscaling context.
2025-05-08 09:27:14 -07:00
Vlad Vasilyeu f32d6cd542 Move DRA provider to autoscaling context. 2025-05-08 09:30:55 +00:00
Kubernetes Prow Robot 34115f8aa0
Merge pull request #8108 from kubernetes/dependabot/docker/vertical-pod-autoscaler/pkg/admission-controller/golang-1.24.3
Bump golang from 1.24.2 to 1.24.3 in /vertical-pod-autoscaler/pkg/admission-controller
2025-05-07 19:35:16 -07:00
Kubernetes Prow Robot d8050d79bc
Merge pull request #8106 from kubernetes/dependabot/docker/vertical-pod-autoscaler/pkg/recommender/golang-1.24.3
Bump golang from 1.24.2 to 1.24.3 in /vertical-pod-autoscaler/pkg/recommender
2025-05-07 19:33:15 -07:00
Kubernetes Prow Robot 53b0f037c7
Merge pull request #8107 from kubernetes/dependabot/docker/vertical-pod-autoscaler/pkg/updater/golang-1.24.3
Bump golang from 1.24.2 to 1.24.3 in /vertical-pod-autoscaler/pkg/updater
2025-05-07 19:31:17 -07:00
dependabot[bot] eea2dcd400
Bump golang in /vertical-pod-autoscaler/pkg/admission-controller
Bumps golang from 1.24.2 to 1.24.3.

---
updated-dependencies:
- dependency-name: golang
  dependency-version: 1.24.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-05-07 19:02:02 +00:00
Ray Wainman d110d05b4b
Update vertical-pod-autoscaler/RELEASE.md
Co-authored-by: Adrian Moisey <adrian@changeover.za.net>
2025-05-07 14:56:46 -04:00
dependabot[bot] 28581fc17e
Bump golang in /vertical-pod-autoscaler/pkg/updater
Bumps golang from 1.24.2 to 1.24.3.

---
updated-dependencies:
- dependency-name: golang
  dependency-version: 1.24.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-05-07 18:47:55 +00:00
dependabot[bot] 5d8f61a690
Bump golang in /vertical-pod-autoscaler/pkg/recommender
Bumps golang from 1.24.2 to 1.24.3.

---
updated-dependencies:
- dependency-name: golang
  dependency-version: 1.24.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-05-07 18:13:46 +00:00
Kubernetes Prow Robot 79a1375afe
Merge pull request #8101 from x13n/estimate-metric
Use exponential rather than arbitrary bucketing
2025-05-07 06:23:16 -07:00
Daniel Kłobuszewski deec4b7fbd Use exponential rather than arbitrary bucketing
Also adds an additional bucket to be able to capture more data points at
the high end.
2025-05-07 14:44:59 +02:00
Kubernetes Prow Robot 6ad982c932
Merge pull request #8099 from x13n/estimate-metric
Introduce a metric measuring heterogeneity of binpacking
2025-05-07 04:53:17 -07:00