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

Add selector spread plugin #2500

Merged
merged 1 commit into from
Sep 26, 2022

Conversation

elinx
Copy link

@elinx elinx commented Sep 21, 2022

also fix #2503

@volcano-sh-bot volcano-sh-bot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Sep 21, 2022
@elinx elinx changed the title add selector spread plugin [WIP] add selector spread plugin Sep 21, 2022
@volcano-sh-bot volcano-sh-bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Sep 21, 2022
@elinx elinx force-pushed the selector-spread branch 2 times, most recently from 1cdb5f8 to 980e308 Compare September 21, 2022 03:30
@@ -145,6 +148,9 @@ func calculateWeight(args framework.Arguments) priorityWeight {
// Checks whether imagelocality.weight is provided or not, if given, modifies the value in weight struct.
args.GetInt(&weight.imageLocalityWeight, ImageLocalityWeight)

// Checks whether selectorspread.weight is provided or not, if given, modifies the value in weight struct.
args.GetInt(&weight.selectorSpreadWeight, ImageLocalityWeight)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why use ImageLocalityWeight in args.GetInt(&weight.selectorSpreadWeight, ImageLocalityWeight)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

a copy-paste mistake 😿 , fixed.

@elinx elinx force-pushed the selector-spread branch 3 times, most recently from df3c5ec to fc25fdc Compare September 22, 2022 03:31
@elinx elinx changed the title [WIP] add selector spread plugin add selector spread plugin Sep 22, 2022
@volcano-sh-bot volcano-sh-bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Sep 22, 2022
@elinx elinx force-pushed the selector-spread branch 2 times, most recently from 0829bf6 to d63ad50 Compare September 22, 2022 03:59
@volcano-sh-bot volcano-sh-bot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Sep 22, 2022
@elinx elinx force-pushed the selector-spread branch 8 times, most recently from 54539a7 to 44e7645 Compare September 22, 2022 12:27
@@ -640,6 +640,13 @@ func newSchedulerCache(config *rest.Config, schedulerNames []string, defaultQueu
UpdateFunc: sc.UpdateNumaInfoV1alpha1,
DeleteFunc: sc.DeleteNumaInfoV1alpha1,
})
// explictly register informers to the factory, otherwise resources listers cannot get anything
// even with no erorr returned.
informerFactory.Core().V1().Namespaces().Informer()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only selectorSpread plugin and topology spread plugin need below informer register?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The InterPodAffinity plugin need the namespace informer, SelectorSpread and PodTopologySpread needs the following four.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@elinx please merge the two commits to one.

done

@william-wang
Copy link
Member

@elinx please merge the two commits to one.

- fix plugin use listers listing resource failed

Signed-off-by: xilinxing <xilinxing@huawei.com>
Copy link
Member

@william-wang william-wang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@volcano-sh-bot volcano-sh-bot added the lgtm Indicates that a PR is ready to be merged. label Sep 26, 2022
@volcano-sh-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: william-wang

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

@volcano-sh-bot volcano-sh-bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 26, 2022
@volcano-sh-bot volcano-sh-bot merged commit 4b9c0de into volcano-sh:release-1.6 Sep 26, 2022
waiterQ pushed a commit to waiterQ/volcano that referenced this pull request Oct 19, 2022
…add podTopologySpread plugin) conflict;

Signed-off-by: shaoqiu <516595344@qq.com>
@william-wang william-wang changed the title add selector spread plugin Add selector spread plugin Jan 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants