-
Notifications
You must be signed in to change notification settings - Fork 4k
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
Refactor estimation #6667
Refactor estimation #6667
Conversation
Hi @kisieland. 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 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/test-infra repository. |
/assign @x13n |
50c8e84
to
03d2bc8
Compare
The grouping should be made by the schedulability equivalence meaning we can introduce optimizations to the binpacking. Introduce a benchmark that estimates capacity needed for 51k pods, which can be grouped to two equivalence groups 50k and 1k.
03d2bc8
to
0dee120
Compare
/ok-to-test |
The optimization uses the fact that pods which are equivalent do not need to be check multiple times against already filled nodes. This changes the time complexity from O(pods*nodes) to O(pods).
0dee120
to
5aa6b2c
Compare
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: kisieland, x13n The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
What type of PR is this?
/kind feature
What this PR does / why we need it:
Introduces optimization to the binpacking estimator, which changes the time complexity from O(pods * nodes) to O(pods) in cases of homogeneous pods.
The PR also introduces a benchmark that shows 5x improvement:
The previous version took ~25s:
The new version takes less than 5s:
Which issue(s) this PR fixes:
Special notes for your reviewer:
Split the PR into two commits:
First one introduces a required pod-equivalence abstraction
Second one uses this new fact in the estimation
For now I kept the logic in one function in the estimation to make clear what changes were made, but I am happy to split it into further functions.
Does this PR introduce a user-facing change?
No
Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.:
NA