Skip to content

Increase range for expected VPA CPU recommendations in e2e #8386

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

kamarabbas99
Copy link
Contributor

What type of PR is this?

/kind flake

What this PR does / why we need it:

These tests can get flaky because the resource consumer consumes 1800 m CPU which can be unevenly distributed across 3 pods which can lead to failure.

Also the tests don't need to append recommendations since vpa-recommender is running in this suite.

Similar PR before: #4469

These tests can get flaky because the resource consumer consumes 1800 m
CPU which can be unevenly distributed across 3 pods which can lead to
failure.

Also the tests dont need to append recommendations since vpa-recommender
is running in this suite.
@k8s-ci-robot
Copy link
Contributor

Adding the "do-not-merge/release-note-label-needed" label because no release-note block was detected, please follow our release note process to remove it.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added kind/flake Categorizes issue or PR as related to a flaky test. do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. labels Jul 29, 2025
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: kamarabbas99
Once this PR has been reviewed and has the lgtm label, please assign jbartosik for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added area/vertical-pod-autoscaler cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Jul 29, 2025
@k8s-ci-robot
Copy link
Contributor

Hi @kamarabbas99. Thanks for your PR.

I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Jul 29, 2025
@kamarabbas99
Copy link
Contributor Author

cc @adrianmoisey

@adrianmoisey
Copy link
Member

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Jul 29, 2025
@omerap12
Copy link
Member

omerap12 commented Aug 1, 2025

Can you explain a bit more on how this supposed to solve the flake?
In here we specify 3 replicas


So we have
rc.ConsumeCPU(600 * replicas)

Which means 1800m in total. but if this load is unevenly distributed across those 3 pods how changing the min/max of a pod helps?
how does

ParseQuantityOrDie("600m"), ParseQuantityOrDie("1800m"))

solve this flake? doesn't a pod can get something like 400m and another will get 800m for example?
What am I missing?

@kamarabbas99
Copy link
Contributor Author

Can you explain a bit more on how this supposed to solve the flake? In here we specify 3 replicas

So we have

rc.ConsumeCPU(600 * replicas)

Which means 1800m in total. but if this load is unevenly distributed across those 3 pods how changing the min/max of a pod helps?
how does

ParseQuantityOrDie("600m"), ParseQuantityOrDie("1800m"))

solve this flake? doesn't a pod can get something like 400m and another will get 800m for example? What am I missing?

Thats a good point. I am actually not sure about that but the similar thing is done for memory.

ParseQuantityOrDie("900Mi"), ParseQuantityOrDie("4000Mi"))

Maybe it will be minimum of 600?

I am not sure how else to reproduce this but I am encountering this flake when I add cpu boost logic to updater(you can maybe add a sleep in RunOnce and it will still flake).

@kamarabbas99
Copy link
Contributor Author

/cc @omerap12

@k8s-ci-robot k8s-ci-robot requested a review from omerap12 August 1, 2025 20:38
@adrianmoisey
Copy link
Member

Is this change fixing a current flake, or a new upcoming flake?

@omerap12
Copy link
Member

omerap12 commented Aug 2, 2025

Can you explain a bit more on how this supposed to solve the flake? In here we specify 3 replicas

So we have

rc.ConsumeCPU(600 * replicas)

Which means 1800m in total. but if this load is unevenly distributed across those 3 pods how changing the min/max of a pod helps?
how does

ParseQuantityOrDie("600m"), ParseQuantityOrDie("1800m"))

solve this flake? doesn't a pod can get something like 400m and another will get 800m for example? What am I missing?

Thats a good point. I am actually not sure about that but the similar thing is done for memory.

ParseQuantityOrDie("900Mi"), ParseQuantityOrDie("4000Mi"))

Maybe it will be minimum of 600?

I am not sure how else to reproduce this but I am encountering this flake when I add cpu boost logic to updater(you can maybe add a sleep in RunOnce and it will still flake).

To be honest - I haven’t seen this flake happen recently, also not in my current PR.
It makes sense that if you set a lower min value and a higher max value, there will probably be fewer flakes,but it doesn’t guarantee that the flake is completely fixed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/vertical-pod-autoscaler cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. kind/flake Categorizes issue or PR as related to a flaky test. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants