-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Enable triggering postcommit via specific file #29549
Conversation
@@ -271,7 +271,6 @@ Please note that jobs with matrix need to have matrix element in the comment. Ex | |||
|
|||
| Workflow name | Matrix | Trigger Phrase | Cron Status | | |||
|:-------------:|:------:|:--------------:|:-----------:| | |||
| [ PostCommit BeamMetrics Publish ](https://github.com/apache/beam/actions/workflows/beam_PostCommit_BeamMetrics_Publish.yml) | N/A |`Run Beam Metrics Deployment`| [](https://github.com/apache/beam/actions/workflows/beam_PostCommit_BeamMetrics_Publish.yml?query=event%3Aschedule) |
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.
BeamMetrics Publish and Website Publish are not really "postcommit" or test suites. It deploys the Beam website or deploys the community metrics dashboard. They should not have comment trigger (which could be used to attack beam website). So renamed them and move to "other" category.
Assigning reviewers. If you would like to opt out of this review, comment R: @damccorm for label build. Available commands:
The PR bot will only process comments in the main thread (not review comments). |
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.
I'm on board with this approach, thanks
.github/workflows/README.md
Outdated
@@ -271,7 +271,6 @@ Please note that jobs with matrix need to have matrix element in the comment. Ex | |||
|
|||
| Workflow name | Matrix | Trigger Phrase | Cron Status | | |||
|:-------------:|:------:|:--------------:|:-----------:| | |||
| [ PostCommit BeamMetrics Publish ](https://github.com/apache/beam/actions/workflows/beam_PostCommit_BeamMetrics_Publish.yml) | N/A |`Run Beam Metrics Deployment`| [](https://github.com/apache/beam/actions/workflows/beam_PostCommit_BeamMetrics_Publish.yml?query=event%3Aschedule) | |||
| [ PostCommit Go ](https://github.com/apache/beam/actions/workflows/beam_PostCommit_Go.yml) | N/A |`Run Go PostCommit`| [](https://github.com/apache/beam/actions/workflows/beam_PostCommit_Go.yml?query=event%3Aschedule) | |
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.
We need to also update all the postcommits in this file to not have trigger phrases listed. Ideally we'd list the file to modify instead.
We should also modify the part that talks about trigger phrases at the top and explain this approach.
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.
updated README.md replacing trigger phrase->trigger file, added instructions on how to manually trigger precommit and postcommits
.github/workflows/beam_Java_JMH.yml
Outdated
@@ -19,7 +19,7 @@ on: | |||
schedule: | |||
- cron: '0 0 * * 0' | |||
pull_request_target: | |||
paths: ['release/trigger_all_tests.json'] | |||
paths: ['release/trigger_all_tests.json', 'beam_Java_JMH.json'] |
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.
Can we put these in a subfolder? Maybe .github/trigger_files
? That way if they accidentally get checked in it doesn't cause issues.
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.
Our guidance could even be to check them in, it does no harm.
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.
added prefix .github/trigger_files
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.
Thanks!
@@ -192,6 +192,8 @@ Please note that jobs with matrix need to have matrix element in the comment. Ex | |||
|
|||
### PreCommit Jobs | |||
|
|||
PreCommit Jobs run in a schedule and also get triggered in a PR if relevant sources has changed. To manually trigger certain PreCommit job, comment with the Trigger Phrase (listed below) in the PR. |
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.
Maybe add something for postcommit jobs here with instructions on how to find the magic file
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.
PostCommit instructions is in PostCommit subsection: https://github.com/apache/beam/blob/6efa27c6e08513ae5b3667d9efcaa6c660525cfc/.github/workflows/README.md#postcommit-jobs
yeah its not quite easy to find given the long README file. Will also mention it in the #comment-triggering-support section
Oh, we should probably do the same for benchmarks as well |
The hope is we can still have the comment trigger in the near future, which is more convenient for developers and reviewers (reviewer can also run the test by comment), as @volatilemolotov working on GitHub App approach. If decided this being long time solution then we can add it to load tests and performance tests |
Workaround #28909
Enable to trigger a PostCommit from pull request by touching a file named "<workflow_name>.json" (/json to get around with RAT PreCommit), as a simple workaround of #28909.
In this way the last piece of gap (comment trigger) is partially fixed and we can shutdown all Jenkins jobs.
Please add a meaningful description for your change here
Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:
addresses #123
), if applicable. This will automatically add a link to the pull request in the issue. If you would like the issue to automatically close on merging the pull request, commentfixes #<ISSUE NUMBER>
instead.CHANGES.md
with noteworthy changes.See the Contributor Guide for more tips on how to make review process smoother.
To check the build health, please visit https://github.com/apache/beam/blob/master/.test-infra/BUILD_STATUS.md
GitHub Actions Tests Status (on master branch)
See CI.md for more information about GitHub Actions CI or the workflows README to see a list of phrases to trigger workflows.