-
Notifications
You must be signed in to change notification settings - Fork 3.7k
[INFRA] Cancel the previous build #9159
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
Conversation
|
|
|
/pulsarbot run-failure-checks |
1 similar comment
|
/pulsarbot run-failure-checks |
|
@codelipenghui We want to support fork as well, so we have to use workflow_run, so this change will only take effect after merging.
https://github.com/potiuk/cancel-workflow-runs#usage
|
|
This action has been added to white-list. See: https://issues.apache.org/jira/browse/INFRA-21287 |
|
I updated this PR. |
|
/pulsarbot run-failure-checks |
1 similar comment
|
/pulsarbot run-failure-checks |
| on: | ||
| workflow_run: | ||
| workflows: | ||
| - 'CI - Build - MacOS' |
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.
is it necessary to write here the list of jobs ?
we can forget about it in the future
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.
The documentation is not very precise and does not describe whether this field is optional. I have not seen any examples that do not define it, so I think it is required. On the other hand, this event doesn't support the exclude list, so it seems to be the only way to exclude "PulsarBot".
https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows#workflow_run
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.
Unfortunately I think this is the only way :( . What you can do is to make some pre-commit check to verify if the list is complete/
eolivelli
left a comment
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.
Lgtm
|
It looks like that this job is being triggered too many times. I wonder if we can restore #8393 |
|
I think the root cause is a bit different. Seems like your workflow/job pattern is different than many other ASF projects, you are simply launching MANY workflows and jobs. Have you considered merging those workflows into smaller number of them ? I think actually the many, many workflows launched by pulsar are the reason for many ASF projects to get blocked queue. See this chart: I am happy to help Pulsar to redesign their CI to be a bit more friendlier towards other projects? I have quite an experience with that - in Apache Airflow I introduced changes that brought the usage of Github Actions by 70% maintaining it's usefulness and I am pretty sure the way you are using GitHub Actions can be optimised. Super Happy to help with that if needed. You can also see the discussions we had about it at the ASF discussion lists recently. I thik this thread from the last weekend describes the current state of affairs rather well: https://lists.apache.org/thread.html/r6130d6d111217b8a90b3b90bbb3029b75b5e2a4b5463f8d2c8f130f6%40%3Cusers.infra.apache.org%3E (you need to sign-up to users@infra.apache.org to view it). Do you think this can be done ? |
|
Hi @potiuk. In the beginning, Pulsar separates the tests into different workflows is for reducing the build and test time. We category with the different tests to make the tests can run parallel. If there has a specific workflow failed, we can re-run the failed workflow and don't need to re-run the entire project tests. |
@potiuk any help is very appreciated We are working on fixing all of the flakes, but this will take time. This will help because we won't need to rerun PR validation more times than needed. Probably it would be interesting to try to merge the workflows: all java tests, all integration tests, all cpp....in some test GitHub repository and work on a new setup. if we let the build continue in case of errors we should have some tool to gather all of the failures and we must be sure that we are not missing any of them |
|
@zymap - I think we can consider running Pulsar CI in the Azure pipeline like Flink is doing. We can reach out to our Flink friends to see how they do it. Example: apache/flink#14756 (comment) https://dev.azure.com/apache-flink/apache-flink/_build/results?buildId=12498&view=results |
|
I have started a draft PIP (Pulsar Improvement Proposal) discussion on the dev@pulsar.apache.org mailing list to address the Github Actions Runner resource consumption issues that currently exist in the Pulsar Github Actions workflows: Please participate in the discussion on the dev@pulsar.apache.org mailing list or place comments / editing suggestions directly on the Google doc: |
|
I will take a look tomorrow. I'v been swamped by some company matters but tomorrow is the day I start going back to life :) |
|
I commented as much as I could and provided all the examples and code links from Apache Airflow :) |
Thank you @potiuk . Very helpful and informative comments with lots of good advice. I'll take a closer look next week when I continue working on the topic. Have a great weekend! |

Master Issue: #9154
Motivation
This PR aims to reduce the GitHub Action usage by cancelling the previous build.
Modifications
Similar to: apache/spark#31098 apache/calcite#2318 (solution suggestted by @vlsi - #9154 (comment))
Verifying this change
(Please pick either of the following options)
This change is a trivial rework / code cleanup without any test coverage.
(or)
This change is already covered by existing tests, such as (please describe tests).
(or)
This change added tests and can be verified as follows:
(example:)
Does this pull request potentially affect one of the following parts:
If
yeswas chosen, please highlight the changesDocumentation