-
Notifications
You must be signed in to change notification settings - Fork 481
Improve RayJob InTreeAutoscaling e2e test #8174
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
base: main
Are you sure you want to change the base?
Conversation
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: hiboyang 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 |
✅ Deploy Preview for kubernetes-sigs-kueue ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
Hi @hiboyang. Thanks for your PR. I'm waiting for a github.com member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the 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. |
|
@mimowo @yaroslava-serdiuk this is the PR to improve e2e test for RayJob with autoscaling. |
|
Thank you! I will leave the first review pass to Yaroslava |
|
/ok-to-test |
| g.Expect(k8sClient.List(ctx, podList, client.InNamespace(ns.Name))).To(gomega.Succeed()) | ||
| // Count pods that have "workers" in their name | ||
| workerPodCount := countWorkerPods(podList) | ||
| g.Expect(workerPodCount).To(gomega.Equal(1), "Expected exactly 5 pods with 'workers' in the name") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| g.Expect(workerPodCount).To(gomega.Equal(1), "Expected exactly 5 pods with 'workers' in the name") | |
| g.Expect(workerPodCount).To(gomega.Equal(1), "Expected exactly 1 pods with 'workers' in the name") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
updated
| # run tasks in parallel to trigger autoscaling (scaling up) | ||
| print(ray.get([my_task.remote(i, 10) for i in range(10)])) | ||
| # run tasks in sequence to trigger scaling down | ||
| print([ray.get(my_task.remote(i, 1)) for i in range(40)])`, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there a reason why you put such high numbers? I'd anticipate a maximum of around 5 being adequate here. If we want to run with 20 or 40 iterations, I suggest we reduce the sleep time accordingly to optimize the test's execution speed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The high numbers are to make the rayjob have enough time to scale up and down. Let me tune these numbers to set them a bit lower.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@yaroslava-serdiuk I updated the tests to make waiting time shorter in rayjob, tried different values multiple times, if setting too short, the test is not stable and may fail randomly. Now get the final values. Would you check?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @yaroslava-serdiuk for checking! I updated the PR again due to git conflict. Would you help to approve again?
|
/release-note-none |
|
/retest |
yaroslava-serdiuk
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
|
LGTM label has been added. Git tree hash: f63009d2190179cca826c4fdb02319e3de6e04a8
|
Co-authored-by: Yaroslava Serdiuk <yaroslava@google.com>
|
New changes are detected. LGTM label has been removed. |
What type of PR is this?
/kind cleanup
What this PR does / why we need it:
This is a follow-up for PR #8082, which adds support for RayJob with autoscaling. This PR improves e2e test to wait for scaling-up/down.
Which issue(s) this PR fixes:
Improve e2e test from PR #8082.
Special notes for your reviewer:
Does this PR introduce a user-facing change?
No