-
Notifications
You must be signed in to change notification settings - Fork 331
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 node selector for each descheduler profile #2168
base: main
Are you sure you want to change the base?
koord-descheduler: support node selector for each descheduler profile #2168
Conversation
Signed-off-by: songtao98 <songtao2603060@gmail.com>
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: 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 |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2168 +/- ##
==========================================
+ Coverage 67.86% 67.89% +0.02%
==========================================
Files 443 443
Lines 41921 41925 +4
==========================================
+ Hits 28451 28466 +15
+ Misses 11014 11005 -9
+ Partials 2456 2454 -2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
@@ -77,6 +77,7 @@ type DeschedulerProfile struct { | |||
Name string | |||
PluginConfig []PluginConfig | |||
Plugins *Plugins | |||
NodeSelector *metav1.LabelSelector |
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.
Shouldn't this be a plugin configuration?
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.
Generally speaking Yes. And actually I recommend plugins to support configuration of multiple NodeSelector
like what LowNodeLoad
do with NodePool
. This PR is intended to solve the kubernetes descheduler plugin adaption problem for multiple node configuration.
Anyway, MigrationController has some bugs for multiple profiles. This PR will be hold for some time.
/hold |
This issue has been automatically marked as stale because it has not had recent activity.
|
Ⅰ. Describe what this PR does
The
DeschedulerConfiguration
supports users to config multiple profiles with different plugin enabled with different pluginConfigs. There are user cases such as to configHighNodeUtilization
plugin with different threshold in different group of nodes, e.g. nodepools. However, most of the plugins only supports to filter pods through specific filters.When dealing with nodes, it is the descheduler framework to decide which nodes can be plugins' checking target through a global
nodeSelector
. This PR enables configuration ofnodeSelector
further into each profile. Note that the descheduler framework will first select nodes at a global level through the outernodeSelector
, then select nodes according to each profile's insidenodeSelector
.Ⅱ. Does this pull request fix one issue?
Ⅲ. Describe how to verify it
Ⅳ. Special notes for reviews
V. Checklist
make test