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

Jenkinsfile update for Gradle Check Publish Optimization #4719

Merged
merged 1 commit into from
May 22, 2024

Conversation

prudhvigodithi
Copy link
Collaborator

@prudhvigodithi prudhvigodithi commented May 22, 2024

Description

Coming from opensearch-project/OpenSearch#11217 (comment), this PR will ensure we have the PR number identified by commitID even for post_merge_action. This data will be used in gradle metrics dashboard OpenSearch Gradle Check Metrics.

With this change we can get the associated PR for failed tests on post_merge_action.

The required library change PR opensearch-project/opensearch-build-libraries#427.
The required gradle check change PR opensearch-project/OpenSearch#13786.

Issues Resolved

Part of: opensearch-project/OpenSearch#3713

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

@prudhvigodithi prudhvigodithi changed the title Gradle Check Publish Optimization Jenkinsfile update for Gradle Check Publish Optimization May 22, 2024
@@ -111,7 +113,7 @@ pipeline {
if (!env.BUILD_CAUSE.contains('Started by user') && !env.BUILD_CAUSE.contains('Started by timer')) {
def pr_url = "${pr_to_clone_url}".replace(".git", "/pull/${pr_number}")
println("Triggered by GitHub: ${pr_to_clone_url}")
if ("$pr_number" == "Null") {
if ("$post_merge_action" == "true") {
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

With this change https://github.com/opensearch-project/OpenSearch/pull/13786/files the pr_number is not null anymore. A new field post_merge_action with true/false is added to identify the push event.

break
case "${pr_number}" == "Null":
case "${post_merge_action}" == "true":
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Same as above.
With this change https://github.com/opensearch-project/OpenSearch/pull/13786/files the pr_number is not null anymore. A new field post_merge_action with true/false is added to identify the push event.

Signed-off-by: Prudhvi Godithi <[email protected]>
@prudhvigodithi
Copy link
Collaborator Author

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.

2 participants