nextflow-io / nextflow-io/nextflow
Nextflow eagerly terminates Azure Batch jobs during execution
Nobody has claimed this yet.
- Dominant language
- Groovy
- Stars
- 3.5k
- Forks
- 811
- Avg merge
- 2d 11h
- Merged PRs (30d)
- 61
Description
New feature
Based on comment: https://github.com/nextflow-io/nextflow/pull/3927#discussion_r1189944527
Azure Batch jobs are terminated during pipeline closing down, see https://github.com/nextflow-io/nextflow/pull/3927.
During that PR, we discussed eagerly changing the setting of each job to onAllTasksComplete = 'terminate' but never looked further into it.
Use case
The main benefit of doing it this way is that if Nextflow fails to close properly (i.e. is killed), most active jobs will be marked as to be terminated and be removed from the active job quota.
Suggested implementation
We just need an "onProcessClose" event to notify when all tasks are created. I've already added it in a number of PRs, like this one: https://github.com/nextflow-io/nextflow/pull/3818
The suggestion from the first PR which could be implemented ☝
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading PR #3927 and its linked discussion, then inspect PR #3818 for the proposed onProcessClose event. Trace where Azure Batch jobs are terminated during pipeline shutdown. Done means active jobs are marked with onAllTasksComplete = 'terminate' once all tasks are created, including when Nextflow fails to close cleanly.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- azure, groovy
- Domain
- cloud
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100