-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Replace the Cancel workflow with native GitHub Action functionality. #32016
Conversation
Recently, GitHub introduced the `concurrency` option for ensuring that only a single job or workflow using the same concurrency group will run at a time. Currently, there is a Cancel workflow in the repo that aims to accomplish the same thing. However, when a backlog exists, the Cancel workflow for each commit does not run until its turn in the queue is reached. This can result in the backlog ballooning. The `concurrency` option in GitHub Actions runs a check when a workflow is queued, skipping the need to wait for an available runner to cancel old workflows.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That looks very promising to me :)
Just a note that after this gets merged, it will only apply to workflow runs created after the first run of each workflow in each pull request. The |
Size Change: 0 B Total Size: 1.62 MB ℹ️ View Unchanged
|
…32016) * Replace the Cancel workflow with native GitHub Action functionality. Recently, GitHub introduced the `concurrency` option for ensuring that only a single job or workflow using the same concurrency group will run at a time. Currently, there is a Cancel workflow in the repo that aims to accomplish the same thing. However, when a backlog exists, the Cancel workflow for each commit does not run until its turn in the queue is reached. This can result in the backlog ballooning. The `concurrency` option in GitHub Actions runs a check when a workflow is queued, skipping the need to wait for an available runner to cancel old workflows. (cherry picked from commit 7b39dd7)
Description
Recently, GitHub introduced the
concurrency
option for ensuring that only a single job or workflow using the same concurrency group will run at a time.Currently, there is a Cancel workflow in the repository that aims to accomplish the same thing. However, when a backlog exists, the Cancel workflow for each commit does not run until its turn in the queue is reached. This can result in the backlog ballooning.
The
concurrency
option in GitHub Actions runs a check when a workflow is queued, skipping the need to wait for an available runner to cancel old workflows.This feature is currently in beta, but is stable enough to use.
This PR introduces
concurrency
to all workflows configured to run onpull_request
. Incomplete workflow runs for previous commits in a PR will be cancelled automatically, whether they are running or queued.The Pull Request Automation workflow does not have
concurrency
because those tasks need to run on each specific commit. This workflow typically runs in 10 seconds or less, so running every workflow is not problematic.For more information on this feature, see:
How has this been tested?
Screenshots
Types of changes
Checklist:
*.native.js
files for terms that need renaming or removal).