Skip to content
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

koord-descheduler: the reservation created during migration skips the original node #1174

Conversation

eahydra
Copy link
Member

@eahydra eahydra commented Apr 3, 2023

Ⅰ. Describe what this PR does

The Reservation created by the migrationController of koord-descheduler may be scheduled to the node where the migrated Pod is located. Although this is the most suitable node from the perspective of the scheduler, it is not suitable from the perspective of descheduling. Therefore, when migrating The created Reservation should skip the original node.

When creating a Reservation, skipped terms will be added to each required term in the original Pod.Spec.Affinity.NodeAffinity to ensure that any condition will not be dispatched to the original node.

Ⅱ. Does this pull request fix one issue?

fix #1114

Ⅲ. Describe how to verify it

Ⅳ. Special notes for reviews

V. Checklist

  • I have written necessary docs and comments
  • I have added necessary unit tests and integration tests
  • All checks passed in make test

… original node

Signed-off-by: Joseph <joseph.t.lee@outlook.com>
@eahydra eahydra added this to the v1.2 milestone Apr 3, 2023
@codecov
Copy link

codecov bot commented Apr 3, 2023

Codecov Report

Patch coverage: 88.09% and project coverage change: -0.29 ⚠️

Comparison is base (acfeb34) 66.56% compared to head (aa1707c) 66.28%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1174      +/-   ##
==========================================
- Coverage   66.56%   66.28%   -0.29%     
==========================================
  Files         277      280       +3     
  Lines       30057    30283     +226     
==========================================
+ Hits        20007    20072      +65     
- Misses       8618     8776     +158     
- Partials     1432     1435       +3     
Flag Coverage Δ
unittests 66.28% <88.09%> (-0.29%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...cheduler/controllers/migration/reservation/util.go 64.10% <88.09%> (ø)

... and 8 files with indirect coverage changes

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@hormes
Copy link
Member

hormes commented Apr 4, 2023

/lgtm

@eahydra
Copy link
Member Author

eahydra commented Apr 5, 2023

/approve

@koordinator-bot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: eahydra

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@koordinator-bot koordinator-bot bot merged commit 7a89022 into koordinator-sh:main Apr 5, 2023
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[proposal]How to avoid A evicted pod is scheduled to the node, which is just evicted a pod 。
3 participants