Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
resource: set default job duration based on current time left
Problem: When a job is submitted without a duration specified and the current graph has a limited duration, the jobspec duration is set to the graph duration. This is not ideal for any job submitted after the first instant of the graph's lifetime, since the job's expiration will be set after the instance has expired. Ideally, jobs without a specified duration should inherit the instance expiration not its duration. Do the next best thing and set the duration to the instance expiration (graph_end) - now, which should result in the expiration of the job matching that of the instance. Fixes #1103
- Loading branch information