Skip to content
Snippets Groups Projects
Commit 8977187e authored by Brian Christiansen's avatar Brian Christiansen
Browse files

Fix priority plugin not removing full run mins.

The basic plugin doesn't do a decay. So it just needs to remove the all of the allocated minutes.
parent 5c843c11
No related branches found
No related tags found
No related merge requests found
......@@ -181,16 +181,11 @@ extern void priority_p_job_end(struct job_record *job_ptr)
assoc_mgr_lock_t locks = { NO_LOCK, WRITE_LOCK, NO_LOCK,
WRITE_LOCK, NO_LOCK, NO_LOCK, NO_LOCK };
/* No unused cpu_run_secs if job ran past its time limit */
if (job_ptr->end_time >= job_ptr->start_time + time_limit_secs)
return;
/* No decaying in basic priority. Just remove the total secs. */
unused_tres_run_secs = xmalloc(sizeof(uint64_t) * slurmctld_tres_cnt);
for (i=0; i<slurmctld_tres_cnt; i++) {
unused_tres_run_secs[i] =
(uint64_t)(job_ptr->start_time +
time_limit_secs - job_ptr->end_time) *
job_ptr->tres_req_cnt[i];
job_ptr->tres_alloc_cnt[i] * time_limit_secs;
}
assoc_mgr_lock(&locks);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment