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

Fix sending LSP4IJ integration build results to Slack channel #880

Conversation

vaisakhkannan
Copy link
Contributor

Fixes #759

I have added code for sending LSP4IJ integration build results to Slack channel. Currently I am using the same channel lsp4ij-monitoring and using the same secret variable SLACK_WEBHOOK_URL

I have tested with the changes in the PR #864 which is opened against the issue #815

@vaisakhkannan
Copy link
Contributor Author

Output screenshot :
Screenshot 2024-07-23 at 6 53 51 PM

We will receive a single Slack notification with the overall build status. If any of the builds fail, the status will be reported as "failed". If all builds succeed, the status will be reported as "succeeded".

Link for the reference : https://github.com/vaisakhkannan/liberty-tools-intellij/actions/runs/10055468368
https://github.com/vaisakhkannan/liberty-tools-intellij/actions/runs/10053225899

@vaisakhkannan
Copy link
Contributor Author

vaisakhkannan commented Jul 24, 2024

Link for the reference latest Cron Job build

https://github.com/vaisakhkannan/liberty-tools-intellij/actions/runs/10072710102

Example builds in different cases:

https://github.com/vaisakhkannan/liberty-tools-intellij/actions/runs/10092590989 --> Status -- Failed ( 2nd Matrix tag is failing )

https://github.com/vaisakhkannan/liberty-tools-intellij/actions/runs/10092549050 --> Status -- Succeeded in all builds

https://github.com/vaisakhkannan/liberty-tools-intellij/actions/runs/10092565454 --> Status -- Failed ( 3rd Matrix tag is failing )

Copy link
Contributor

@anusreelakshmi934 anusreelakshmi934 left a comment

Choose a reason for hiding this comment

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

Looks good

@TrevCraw TrevCraw requested a review from mrglavas July 24, 2024 20:00
@vaisakhkannan vaisakhkannan marked this pull request as draft July 25, 2024 08:49
@vaisakhkannan
Copy link
Contributor Author

I marked this PR as draft because I need to test with multiple open PRs of LSP4IJ Repo

@vaisakhkannan
Copy link
Contributor Author

Today, I tried to test the changes in this PR with multiple open PRs of LSP4IJ. Since it only has one PR without merge conflicts, I used my fork repo API to test with multiple open PRs. I found an issue where the Cron Job builds are taking PRs with merge conflicts.

https://github.com/vaisakhkannan/liberty-tools-intellij/actions/runs/10091019128

PR number 31 is the only PR which do not having merge conflicts. But Cron Job builds taking all the PRs.

Upon further inspection of the API, I discovered that there are several other values present for mergeable_state.

image

We are currently checking only one condition ( if [[ "$mergeable_state" != "dirty" ]] ). Therefore, I believe we need to add an additional condition check to confirm PRs without merge conflicts.

@vaisakhkannan vaisakhkannan marked this pull request as ready for review August 1, 2024 13:21
Copy link
Contributor

@mrglavas mrglavas left a comment

Choose a reason for hiding this comment

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

Reviewed with Vaisakh and the team this morning. I just reviewed the computed build status for the reference builds. It all looked good, so I'm approving this PR now. Great work! Thanks again.

@vaisakhkannan vaisakhkannan merged commit ebba3f4 into OpenLiberty:lsp4ij-market-0.0.2-integration Aug 5, 2024
2 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants