flux-framework / flux-core

core services for the Flux resource management framework
GNU Lesser General Public License v3.0
168 stars 50 forks source link

job-manager: clean up queue code #6448

Closed garlick closed 6 days ago

garlick commented 6 days ago

Problem: queues in the job manager are a bit strange(!) and the code is not well documented.

This is some gratuitous cleanup based on my experience revisiting the code after a long haitus. Hopefully it makes things a little more clear for the next visitor.

garlick commented 6 days ago

Great! Thank you, I'll set MWP.

codecov[bot] commented 6 days ago

Codecov Report

Attention: Patch coverage is 92.62673% with 16 lines in your changes missing coverage. Please review.

Project coverage is 83.61%. Comparing base (8425e3c) to head (3a779fe). Report is 7 commits behind head on master.

Files with missing lines Patch % Lines
src/modules/job-manager/queue.c 92.48% 16 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #6448 +/- ## ========================================== - Coverage 83.62% 83.61% -0.02% ========================================== Files 523 523 Lines 87488 87505 +17 ========================================== Hits 73164 73164 - Misses 14324 14341 +17 ``` | [Files with missing lines](https://app.codecov.io/gh/flux-framework/flux-core/pull/6448?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=flux-framework) | Coverage Δ | | |---|---|---| | [src/modules/job-manager/job-manager.c](https://app.codecov.io/gh/flux-framework/flux-core/pull/6448?src=pr&el=tree&filepath=src%2Fmodules%2Fjob-manager%2Fjob-manager.c&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=flux-framework#diff-c3JjL21vZHVsZXMvam9iLW1hbmFnZXIvam9iLW1hbmFnZXIuYw==) | `63.56% <100.00%> (ø)` | | | [src/modules/job-manager/restart.c](https://app.codecov.io/gh/flux-framework/flux-core/pull/6448?src=pr&el=tree&filepath=src%2Fmodules%2Fjob-manager%2Frestart.c&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=flux-framework#diff-c3JjL21vZHVsZXMvam9iLW1hbmFnZXIvcmVzdGFydC5j) | `82.17% <100.00%> (ø)` | | | [src/modules/job-manager/queue.c](https://app.codecov.io/gh/flux-framework/flux-core/pull/6448?src=pr&el=tree&filepath=src%2Fmodules%2Fjob-manager%2Fqueue.c&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=flux-framework#diff-c3JjL21vZHVsZXMvam9iLW1hbmFnZXIvcXVldWUuYw==) | `79.88% <92.48%> (+1.11%)` | :arrow_up: | ... and [11 files with indirect coverage changes](https://app.codecov.io/gh/flux-framework/flux-core/pull/6448/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=flux-framework)

🚨 Try these New Features: