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-scheduler: DeviceShare supports scoring #1534

Merged

Conversation

eahydra
Copy link
Member

@eahydra eahydra commented Aug 7, 2023

Ⅰ. Describe what this PR does

The DeviceShare plugin supports scoring.

  • Nodes are scored according to the normalized resource name.
  • When allocating devices in the Reserve stage, device instances are sorted according to the scoring strategy.

Ⅱ. Does this pull request fix one issue?

fix #1457

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

@codecov
Copy link

codecov bot commented Aug 7, 2023

Codecov Report

Patch coverage: 77.87% and project coverage change: +0.06% 🎉

Comparison is base (d38e498) 64.85% compared to head (054b96b) 64.92%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1534      +/-   ##
==========================================
+ Coverage   64.85%   64.92%   +0.06%     
==========================================
  Files         348      349       +1     
  Lines       35641    35950     +309     
==========================================
+ Hits        23115    23340     +225     
- Misses      10829    10890      +61     
- Partials     1697     1720      +23     
Flag Coverage Δ
unittests 64.92% <77.87%> (+0.06%) ⬆️

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

Files Changed Coverage Δ
pkg/scheduler/plugins/deviceshare/plugin.go 60.81% <55.00%> (-1.31%) ⬇️
pkg/scheduler/plugins/deviceshare/reservation.go 78.87% <72.46%> (-2.50%) ⬇️
pkg/scheduler/plugins/deviceshare/scoring.go 74.26% <74.26%> (ø)
pkg/scheduler/plugins/deviceshare/device_cache.go 86.96% <90.14%> (-0.84%) ⬇️
pkg/scheduler/plugins/deviceshare/allocator.go 90.00% <100.00%> (+2.50%) ⬆️
.../scheduler/plugins/deviceshare/device_resources.go 89.07% <100.00%> (+1.33%) ⬆️

... and 3 files with indirect coverage changes

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

@ZiMengSheng
Copy link
Contributor

/lgtm

Copy link
Member

@jasonliu747 jasonliu747 left a comment

Choose a reason for hiding this comment

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

/lgtm

Signed-off-by: Joseph <joseph.t.lee@outlook.com>
@koordinator-bot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

Approval requirements bypassed by manually added approval.

This pull-request has been approved by:

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

@jasonliu747
Copy link
Member

/lgtm

@koordinator-bot koordinator-bot bot added the lgtm label Aug 10, 2023
@koordinator-bot koordinator-bot bot merged commit 3a366fe into koordinator-sh:main Aug 10, 2023
16 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] DeviceShare should support scoring.
3 participants