Skip to content

Conversation

@lhotari
Copy link
Member

@lhotari lhotari commented Oct 28, 2020

Motivation

Currently a single user can cause the Github Actions / Workflows based CI to get overloaded when commits are pushed to a PR branch frequently, one by one. To mitigate this issue, cancel any previous Github Actions runs that are not completed for a given workflow, for a particular branch / PR. This can be achieved by using the https://github.com/marketplace/actions/cancel-workflow-action .
There are multiple cancel actions available. This particular one was picked based on its popularity.

Modifications

Append each workflow with the cancel workflow action step.

A similar change was made in Pulsar CI in PR apache/pulsar#8393

- Cancel any previous runs that are not completed for a given workflow
  for a particular branch / PR.
  - See https://github.com/marketplace/actions/cancel-workflow-action
Copy link
Contributor

@eolivelli eolivelli left a comment

Choose a reason for hiding this comment

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

LGTM

@Ghatage PTAL a look

Copy link
Contributor

@Ghatage Ghatage left a comment

Choose a reason for hiding this comment

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

LGTM.

@lhotari Just for my info, can you please explain why we're choosing 0.6.0? Is that the latest?

@lhotari
Copy link
Member Author

lhotari commented Oct 28, 2020

Just for my info, can you please explain why we're choosing 0.6.0? Is that the latest?

yes, it's the latest. I used the code snippet from https://github.com/marketplace/actions/cancel-workflow-action .

@Ghatage Ghatage added this to the 4.12.0 milestone Oct 28, 2020
@Ghatage Ghatage merged commit d8683b0 into apache:master Oct 28, 2020
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.

3 participants