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

Cancel in-progress/pending workflows of the same branch #747

Merged
merged 1 commit into from
Sep 14, 2021

Conversation

root-expert
Copy link
Member

Concurrency setting documentation.

This PR introduces a Travis-like behavior which was cancelling any previous jobs when new changes were pushed.
This can help with modules whose acceptance tests are time consuming and stacking up workflows can lead to hit the concurrency limit pretty quickly.

A example could be the voxpupuli/puppet-zabbix module whose acceptance tests are lasting up to an hour, if a contributor pushes 5 changes we end up with ~60 jobs in the queue.

Caveats:

  • This setting is currently in beta and maybe we don't want to merge it to our modulesync just yet

I haven't thought of all the cons of this change, so I'm open to discussion 😄

Signed-off-by: Christos Papageorgiou <christos.papageorgioy@gmail.com>
@bastelfreak
Copy link
Member

thanks for this, did you test the syntax on any module?

@root-expert
Copy link
Member Author

thanks for this, did you test the syntax on any module?

Maybe I can test it here https://github.com/voxpupuli/puppet-example ?

@bastelfreak
Copy link
Member

sure. you can add such a PR to all of our modules.

Copy link
Member

@ekohl ekohl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks very useful! I'd be OK with trying this.

@root-expert
Copy link
Member Author

Tested in zabbix module.

https://github.com/voxpupuli/puppet-zabbix/actions/runs/1169817369 was cancelled automatically

@root-expert
Copy link
Member Author

Also re-triggered this job just to be sure it doesn't interfere with other PRs

@root-expert root-expert changed the title Cancel in progress actions of the same branch Cancel in-progress/pending workflows of the same branch Aug 26, 2021
@bastelfreak bastelfreak merged commit 491eab9 into voxpupuli:master Sep 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants