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: support evicting all bare pods in migration controller #2102

Merged

Conversation

songtao98
Copy link
Contributor

Ⅰ. Describe what this PR does

This PR add a new arg EvictAllBarePods into MigrationController. If this arg is set as true, all bare pods including failed phase can be evicted. The default value is false. Users should know the risk and use this arg carefully because pods without OwnerRef cannot be re-created by default.

To implement this, I mocked the filter function in DefaultEvictor. Other functions used by MigrationController such as PreEvictionFilter are still be imported by the adapter.

Ⅱ. Does this pull request fix one issue?

fixes #2099

Ⅲ. 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

Copy link

codecov bot commented Jun 13, 2024

Codecov Report

Attention: Patch coverage is 60.00000% with 14 lines in your changes missing coverage. Please review.

Project coverage is 68.66%. Comparing base (ae25a92) to head (d45cf05).
Report is 1 commits behind head on main.

Files Patch % Lines
...heduler/controllers/migration/arbitrator/filter.go 0.00% 12 Missing ⚠️
pkg/descheduler/evictions/evictions.go 91.30% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2102      +/-   ##
==========================================
+ Coverage   68.65%   68.66%   +0.01%     
==========================================
  Files         430      430              
  Lines       40056    40071      +15     
==========================================
+ Hits        27499    27515      +16     
+ Misses      10192    10191       -1     
  Partials     2365     2365              
Flag Coverage Δ
unittests 68.66% <60.00%> (+0.01%) ⬆️

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

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@songtao98 songtao98 force-pushed the support_evict_all_bare_pod branch 2 times, most recently from 4046bf3 to 1b91b40 Compare June 14, 2024 17:27
Signed-off-by: songtao98 <songtao2603060@gmail.com>
@ZiMengSheng
Copy link
Contributor

/lgtm

@hormes
Copy link
Member

hormes commented Jun 17, 2024

/approve

@koordinator-bot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: hormes

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 6f1debb into koordinator-sh:main Jun 17, 2024
24 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] koord-descheduler: add a new arg evictAllBarePods to MigrationController
3 participants