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

WIP: add jobtap plugin for preemption #6580

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

garlick
Copy link
Member

@garlick garlick commented Jan 24, 2025

This is a first cut at a jobtap plugin that dispatches preemptible jobs when there is job pressure from non-preemptible jobs, as discussed in #6524. It handles preemptible-after > 0 and doesn't preempt jobs in queues that don't have pressure.

That's about the extent of its smarts!

There's a comment at the top of the plugin that explains how it works, but the quick summary is that there are currently two "handlers" that are invoked periodically while there are potential victims and job pressure. If the overkill handler is selected, it kills all eligible victims in one go. If the onekill handler is selected, it kills one random victim, then waits a while and tries again if there is still pressure.

This is a WIP because probably we'll need another handler that's smart about node counts, and because testing doesn't cover queues yet. I was reaching a quitting point for the weekend and wanted to get this up.

Problem: RFC 14 specifies that a job can set the preemptible-after
system attribute in their jobspec to signal that the job can be
preempted, but flux-core and flux-sched currently ignore this.

The scheduler is the proper place to handle preemption, but in the
mean time, provide a jobtap plugin that can do a sloppy job of it
without knowledge of the schedule.
Problem: there are no tests for the killbot preemption plugin.

Add a sharness test.
Copy link

codecov bot commented Jan 24, 2025

Codecov Report

Attention: Patch coverage is 84.74576% with 45 lines in your changes missing coverage. Please review.

Project coverage is 79.49%. Comparing base (16f7233) to head (47a95a8).
Report is 8 commits behind head on master.

Files with missing lines Patch % Lines
src/modules/job-manager/plugins/killbot.c 84.74% 45 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #6580      +/-   ##
==========================================
+ Coverage   79.47%   79.49%   +0.01%     
==========================================
  Files         531      532       +1     
  Lines       88312    88607     +295     
==========================================
+ Hits        70184    70434     +250     
- Misses      18128    18173      +45     
Files with missing lines Coverage Δ
src/modules/job-manager/plugins/killbot.c 84.74% <84.74%> (ø)

... and 11 files with indirect coverage changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant