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

refactor: remove agentID type from agentrm #9040

Merged
merged 1 commit into from
Mar 26, 2024

Conversation

jesse-amano-hpe
Copy link
Contributor

@jesse-amano-hpe jesse-amano-hpe commented Mar 22, 2024

Description

DET-9976

Removes the agentID type in favor of using aproto.ID throughout package agentrm.

Test Plan

N/A

Commentary (optional)

A little surprising that there's a net gain of SLOC, but it's because of all the new import...aproto lines.

Also, this refactor touches a ton of untested code, but I promise it's purely a static change >.<

Checklist

  • Changes have been manually QA'd
  • User-facing API changes need the "User-facing API Change" label.
  • Release notes should be added as a separate file under docs/release-notes/.
    See Release Note for details.
  • Licenses should be included for new code which was copied and/or modified from any external code.

@cla-bot cla-bot bot added the cla-signed label Mar 22, 2024
Copy link

codecov bot commented Mar 22, 2024

Codecov Report

Attention: Patch coverage is 54.16667% with 11 lines in your changes are missing coverage. Please review.

Project coverage is 47.80%. Comparing base (e4bc377) to head (b35e765).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #9040      +/-   ##
==========================================
- Coverage   47.80%   47.80%   -0.01%     
==========================================
  Files        1161     1161              
  Lines      143646   143646              
  Branches     2373     2373              
==========================================
- Hits        68673    68672       -1     
- Misses      74820    74821       +1     
  Partials      153      153              
Flag Coverage Δ
backend 42.94% <54.16%> (-0.01%) ⬇️
harness 63.84% <ø> (ø)
web 40.90% <ø> (ø)

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

Files Coverage Δ
master/internal/rm/agentrm/agent_model.go 100.00% <ø> (ø)
master/internal/rm/agentrm/agent_state.go 83.84% <100.00%> (ø)
master/internal/rm/agentrm/agents.go 63.30% <100.00%> (ø)
master/internal/rm/agentrm/fair_share.go 95.85% <ø> (ø)
master/internal/rm/agentrm/fitting.go 95.68% <ø> (ø)
master/internal/rm/agentrm/priority.go 87.50% <100.00%> (ø)
master/internal/rm/agentrm/round_robin.go 66.66% <ø> (ø)
master/internal/rm/agentrm/summaries.go 60.86% <ø> (ø)
master/internal/rm/agentrm/resource_pool.go 34.13% <0.00%> (ø)
master/internal/rm/agentrm/resources.go 0.00% <0.00%> (ø)
... and 2 more

... and 1 file with indirect coverage changes

Copy link

netlify bot commented Mar 22, 2024

Deploy Preview for determined-ui canceled.

Name Link
🔨 Latest commit b35e765
🔍 Latest deploy log https://app.netlify.com/sites/determined-ui/deploys/65fd2045804edc0008d07d73

@jesse-amano-hpe jesse-amano-hpe marked this pull request as ready for review March 22, 2024 14:24
@jesse-amano-hpe jesse-amano-hpe requested a review from a team as a code owner March 22, 2024 14:24
Copy link
Contributor

@amandavialva01 amandavialva01 left a comment

Choose a reason for hiding this comment

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

This is a resource management ticket but was a pretty straight-forward refactor, so I reviewed it...LGTM!
Thanks for helping get rid of some unnecessary back-and-forth casting, and for removing the duplicate type.

Copy link
Contributor

@stoksc stoksc left a comment

Choose a reason for hiding this comment

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

lgtm (didn't review a ton, if the compiler is happy i assume this is fine)

@jesse-amano-hpe jesse-amano-hpe merged commit 1202d5c into main Mar 26, 2024
75 of 89 checks passed
@jesse-amano-hpe jesse-amano-hpe deleted the jta/DET-9976/simplify-agent-id-references branch March 26, 2024 16:10
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.

3 participants