From 3e323dee64abb7c1d17d0df3af51da37afffffd2 Mon Sep 17 00:00:00 2001 From: Zelin Hao Date: Tue, 16 Aug 2022 17:21:09 -0700 Subject: [PATCH 1/6] New jenkins library to generate buildInfo.yml Signed-off-by: Zelin Hao --- .../distribution-build.jenkinsfile | 160 ++++++++++++++++- .../opensearch/distribution-build.jenkinsfile | 158 ++++++++++++++++- tests/jenkins/TestBuildInfoYaml.groovy | 33 ++++ tests/jenkins/TestGetRepositoryCommit.groovy | 31 ---- tests/jenkins/data/BuildInfo.yml | 164 ++++++++++++++++++ tests/jenkins/data/opensearch-2.2.0.yml | 152 ++++++++++++++++ tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile | 47 +++++ .../jobs/BuildInfoYaml_Jenkinsfile.txt | 96 ++++++++++ .../jobs/GetRepositoryCommit_Jenkinsfile | 24 --- .../jobs/GetRepositoryCommit_Jenkinsfile.txt | 62 ------- .../lib-testers/BuildInfoYamlLibTester.groovy | 46 +++++ .../GetRepositoryCommitLibTester.groovy | 34 ---- vars/buildInfoYaml.groovy | 69 ++++++++ vars/getRepositoryCommit.groovy | 55 ------ 14 files changed, 913 insertions(+), 218 deletions(-) create mode 100644 tests/jenkins/TestBuildInfoYaml.groovy delete mode 100644 tests/jenkins/TestGetRepositoryCommit.groovy create mode 100644 tests/jenkins/data/BuildInfo.yml create mode 100644 tests/jenkins/data/opensearch-2.2.0.yml create mode 100644 tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile create mode 100644 tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt delete mode 100644 tests/jenkins/jobs/GetRepositoryCommit_Jenkinsfile delete mode 100644 tests/jenkins/jobs/GetRepositoryCommit_Jenkinsfile.txt create mode 100644 tests/jenkins/lib-testers/BuildInfoYamlLibTester.groovy delete mode 100644 tests/jenkins/lib-testers/GetRepositoryCommitLibTester.groovy create mode 100644 vars/buildInfoYaml.groovy delete mode 100644 vars/getRepositoryCommit.groovy diff --git a/jenkins/opensearch-dashboards/distribution-build.jenkinsfile b/jenkins/opensearch-dashboards/distribution-build.jenkinsfile index 50e64ce4f4..678542a683 100644 --- a/jenkins/opensearch-dashboards/distribution-build.jenkinsfile +++ b/jenkins/opensearch-dashboards/distribution-build.jenkinsfile @@ -65,7 +65,7 @@ pipeline { } } } - stage('Get Repository Commits') { + stage('Initialize the buildInfoYaml report') { agent { docker { label AGENT_X64 @@ -75,16 +75,18 @@ pipeline { } steps { script { - getRepositoryCommit( - componentName: "${COMPONENT_NAME}", - inputManifest: "manifests/${INPUT_MANIFEST}", - outputFile: "commits.yml" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "manifests/$INPUT_MANIFEST", + outputFile: "buildInfo.yml", + status: "NOT_STARTED", + stage: "START" ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" } } post { always { - archiveArtifacts artifacts: 'commits.yml' postCleanup() } } @@ -132,6 +134,17 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_X64) ] + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: integTestResults.getId(), + stage: "integ_test_x64" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + + env.ARTIFACT_URL_X64_TAR_INTEG_TEST_RESULT = createTestResultsMessage( testType: "Integ Tests (x64, tar)", status: integTestResults.getResult(), @@ -153,6 +166,16 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_X64) ] + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: bwcTestResults.getId(), + stage: "bwc_test_x64" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + env.ARTIFACT_URL_X64_TAR_BWC_TEST_RESULT = createTestResultsMessage( testType: "BWC Tests (x64, tar)", status: bwcTestResults.getResult(), @@ -176,6 +199,28 @@ pipeline { postCleanup() } } + success { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "SUCCESS", + stage: "x64_tar" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } + failure { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "FAILURE", + stage: "x64_tar" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } } } stage('build-and-test-linux-x64-rpm') { @@ -253,6 +298,28 @@ pipeline { } } post { + success { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "SUCCESS", + stage: "x64_rpm" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } + failure { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "FAILURE", + stage: "x64_rpm" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } always { script { lib.jenkins.Messages.new(this).add( @@ -339,6 +406,17 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_ARM64) ] + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: integTestResults.getId(), + stage: "integ_test_arm64" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + + env.ARTIFACT_URL_ARM64_TAR_INTEG_TEST_RESULT = createTestResultsMessage( testType: "Integ Tests (arm64, tar)", status: integTestResults.getResult(), @@ -360,6 +438,16 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_ARM64) ] + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: bwcTestResults.getId(), + stage: "bwc_test_arm64" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + env.ARTIFACT_URL_ARM64_TAR_BWC_TEST_RESULT = createTestResultsMessage( testType: "BWC Tests (arm64, tar)", status: bwcTestResults.getResult(), @@ -383,6 +471,28 @@ pipeline { postCleanup() } } + success { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "SUCCESS", + stage: "arm64_tar" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } + failure { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "FAILURE", + stage: "arm64_tar" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } } } } @@ -461,6 +571,28 @@ pipeline { } } post { + success { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "SUCCESS", + stage: "arm64_rpm" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } + failure { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "FAILURE", + stage: "arm64_rpm" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } always { script { lib.jenkins.Messages.new(this).add( @@ -527,6 +659,22 @@ pipeline { } } post { + always { + node(AGENT_X64) { + script { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: currentBuild.result, + stage: "COMPLETE" + ) + archiveArtifacts artifacts: 'buildInfo.yml' + postCleanup() + } + } + } success { node(AGENT_X64) { script { diff --git a/jenkins/opensearch/distribution-build.jenkinsfile b/jenkins/opensearch/distribution-build.jenkinsfile index b463915a4e..8fb694efb9 100644 --- a/jenkins/opensearch/distribution-build.jenkinsfile +++ b/jenkins/opensearch/distribution-build.jenkinsfile @@ -65,7 +65,7 @@ pipeline { } } } - stage('Get Repository Commits') { + stage('Initialize the buildInfoYaml report') { agent { docker { label AGENT_X64 @@ -75,16 +75,18 @@ pipeline { } steps { script { - getRepositoryCommit( - componentName: "${COMPONENT_NAME}", - inputManifest: "manifests/${INPUT_MANIFEST}", - outputFile: "commits.yml" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "manifests/$INPUT_MANIFEST", + outputFile: "buildInfo.yml", + status: "NOT_STARTED", + stage: "START" ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" } } post { always { - archiveArtifacts artifacts: 'commits.yml' postCleanup() } } @@ -233,6 +235,16 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_X64) ] + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: integTestResults.getId(), + stage: "integ_test_x64" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + env.ARTIFACT_URL_X64_TAR_INTEG_TEST_RESULT = createTestResultsMessage( testType: "Integ Tests (x64, tar)", status: integTestResults.getResult(), @@ -254,6 +266,16 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_X64) ] + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: bwcTestResults.getId(), + stage: "bwc_test_x64" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + env.ARTIFACT_URL_X64_TAR_BWC_TEST_RESULT = createTestResultsMessage( testType: "BWC Tests (x64, tar)", status: bwcTestResults.getResult(), @@ -277,6 +299,28 @@ pipeline { postCleanup() } } + success { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "SUCCESS", + stage: "x64_tar" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } + failure { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "FAILURE", + stage: "x64_tar" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } } } stage('build-and-test-x64-rpm') { @@ -354,6 +398,28 @@ pipeline { } } post { + success { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "SUCCESS", + stage: "x64_rpm" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } + failure { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "FAILURE", + stage: "x64_rpm" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } always { script { lib.jenkins.Messages.new(this).add( @@ -407,6 +473,16 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_ARM64) ] + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: integTestResults.getId(), + stage: "integ_test_arm64" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + env.ARTIFACT_URL_ARM64_TAR_INTEG_TEST_RESULT = createTestResultsMessage( testType: "Integ Tests (arm64, tar)", status: integTestResults.getResult(), @@ -428,6 +504,16 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_ARM64) ] + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: bwcTestResults.getId(), + stage: "bwc_test_arm64" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + env.ARTIFACT_URL_ARM64_TAR_BWC_TEST_RESULT = createTestResultsMessage( testType: "BWC Tests (arm64, tar)", status: bwcTestResults.getResult(), @@ -451,6 +537,28 @@ pipeline { postCleanup() } } + success { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "SUCCESS", + stage: "arm64_tar" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } + failure { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "FAILURE", + stage: "arm64_tar" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } } } stage('build-and-test-arm64-rpm') { @@ -528,6 +636,28 @@ pipeline { } } post { + success { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "SUCCESS", + stage: "arm64_rpm" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } + failure { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: "FAILURE", + stage: "arm64_rpm" + ) + stash includes: "buildInfo.yml", name: "buildInfo_manifest" + } always { script { lib.jenkins.Messages.new(this).add( @@ -594,6 +724,22 @@ pipeline { } } post { + always { + node(AGENT_X64) { + script { + unstash "buildInfo_manifest" + buildInfoYaml( + componentName: COMPONENT_NAME, + inputManifest: "buildInfo.yml", + outputFile: "buildInfo.yml", + status: currentBuild.result, + stage: "COMPLETE" + ) + archiveArtifacts artifacts: 'buildInfo.yml' + postCleanup() + } + } + } success { node(AGENT_X64) { script { diff --git a/tests/jenkins/TestBuildInfoYaml.groovy b/tests/jenkins/TestBuildInfoYaml.groovy new file mode 100644 index 0000000000..fe364c3a3b --- /dev/null +++ b/tests/jenkins/TestBuildInfoYaml.groovy @@ -0,0 +1,33 @@ +/* + * SPDX-License-Identifier: Apache-2.0 + * + * The OpenSearch Contributors require contributions made to + * this file be licensed under the Apache-2.0 license or a + * compatible open source license. + */ + +import jenkins.tests.BuildPipelineTest +import org.junit.Before +import org.junit.Test + + +class TestBuildInfoYaml extends BuildPipelineTest { + + @Before + void setUp() { + this.registerLibTester(new BuildInfoYamlLibTester( + '', + 'tests/jenkins/data/opensearch-2.2.0.yml', + 'tests/jenkins/data/buildInfo.yml', + 'NOT_STARTED', + 'START' + ) + ) + super.setUp() + } + + @Test + void testBuildInfoYaml() { + super.testPipeline("tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile") + } +} diff --git a/tests/jenkins/TestGetRepositoryCommit.groovy b/tests/jenkins/TestGetRepositoryCommit.groovy deleted file mode 100644 index 8d44c89735..0000000000 --- a/tests/jenkins/TestGetRepositoryCommit.groovy +++ /dev/null @@ -1,31 +0,0 @@ -/* - * SPDX-License-Identifier: Apache-2.0 - * - * The OpenSearch Contributors require contributions made to - * this file be licensed under the Apache-2.0 license or a - * compatible open source license. - */ - -import jenkins.tests.BuildPipelineTest -import org.junit.Before -import org.junit.Test - - -class TestGetRepositoryCommit extends BuildPipelineTest { - - @Before - void setUp() { - this.registerLibTester(new GetRepositoryCommitLibTester( - '', - 'tests/jenkins/data/opensearch-2.0.0.yml', - 'commits.yml' - ) - ) - super.setUp() - } - - @Test - void testGetRepositoryCommit() { - super.testPipeline("tests/jenkins/jobs/GetRepositoryCommit_Jenkinsfile") - } -} diff --git a/tests/jenkins/data/BuildInfo.yml b/tests/jenkins/data/BuildInfo.yml new file mode 100644 index 0000000000..5c585c14fc --- /dev/null +++ b/tests/jenkins/data/BuildInfo.yml @@ -0,0 +1,164 @@ +---schema-version: '1.0' +build: + name: OpenSearch + version: 2.2.0 + status: SUCCESS + number: '30' +ci: + image: + name: opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2 + args: -e JAVA_HOME=/opt/java/openjdk-17 +components: + - name: OpenSearch + repository: https://github.com/opensearch-project/OpenSearch.git + ref: b1017fa3b9a1c781d4f34ecee411e0cdf930a515 + checks: + - gradle:publish + - gradle:properties:version + - name: common-utils + repository: https://github.com/opensearch-project/common-utils.git + ref: ae064c5668f3d46ba8f47ad6e7ea23a14ede557b + platforms: + - linux + checks: + - gradle:publish + - gradle:properties:version + - name: job-scheduler + repository: https://github.com/opensearch-project/job-scheduler.git + ref: a5013073ec8de9b7af6fa439c2f4d6fd9af8881d + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: ml-commons + repository: https://github.com/opensearch-project/ml-commons.git + ref: a7d269500f8667fdd4cd4d582c7148a7e7fb557c + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version: opensearch-ml-plugin + - name: performance-analyzer + repository: https://github.com/opensearch-project/performance-analyzer.git + ref: 3a75d7d5a6302b3c9fd78fb7104f90689d407484 + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: security + repository: https://github.com/opensearch-project/security.git + ref: ff17b025d15793d600f4b31d6dd4bbde97030f39 + platforms: + - linux + - name: geospatial + repository: https://github.com/opensearch-project/geospatial.git + ref: a71475ab3b0de008ca352e290d99fb3b53f1a1c5 + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: k-NN + repository: https://github.com/opensearch-project/k-NN.git + ref: 53185a0f165ebe1f8c3e01fd80a867727ba3674f + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: cross-cluster-replication + repository: https://github.com/opensearch-project/cross-cluster-replication.git + ref: 719634b60056e48e35cccba1f1ed3a0a43bb90e5 + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: notifications-core + repository: https://github.com/opensearch-project/notifications.git + ref: 01b4aa8886b4bb8faabf482bf9f4baaa441015fe + platforms: + - linux + working_directory: notifications + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version: opensearch-notifications-core + - name: notifications + repository: https://github.com/opensearch-project/notifications.git + ref: 01b4aa8886b4bb8faabf482bf9f4baaa441015fe + platforms: + - linux + working_directory: notifications + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version: notifications + - name: anomaly-detection + repository: https://github.com/opensearch-project/anomaly-detection.git + ref: 04f27418fe97110635b08dd986d77ce0ecc384ec + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: asynchronous-search + repository: https://github.com/opensearch-project/asynchronous-search.git + ref: 4f1f992c6bb134dab191042a87216f1616be8a27 + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: alerting + repository: https://github.com/opensearch-project/alerting.git + ref: b3d676f70b0df8df9cab0919a147ed395c568797 + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version: alerting + - name: index-management + repository: https://github.com/opensearch-project/index-management.git + ref: 8eb5da6b0317506ee0160ddbbc53a14550cbcd5d + platforms: + - linux + checks: + - gradle:properties:version + - name: sql + repository: https://github.com/opensearch-project/sql.git + ref: 454122d3c73dcf8944800720e2116fd6540d3b26 + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version: opensearch-sql-plugin + - name: opensearch-observability + repository: https://github.com/opensearch-project/observability + ref: 4055decd159c2cff401b43006f6ccba73e6f67b6 + platforms: + - linux + working_directory: opensearch-observability + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: dashboards-reports + repository: https://github.com/opensearch-project/dashboards-reports.git + ref: 1d3980ab2d93a89acd0a5716f575a222389b9e8d + platforms: + - linux + working_directory: reports-scheduler + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version +results: + integ_test_x64: NOT_STARTED + bwc_test_x64: NOT_STARTED + integ_test_arm64: NOT_STARTED + bwc_test_arm64: NOT_STARTED + x64_tar: NOT_STARTED + arm64_tar: NOT_STARTED + x64_rpm: NOT_STARTED + arm64_rpm: NOT_STARTED + duration: 154442 + startTimestamp: 1660345758679 diff --git a/tests/jenkins/data/opensearch-2.2.0.yml b/tests/jenkins/data/opensearch-2.2.0.yml new file mode 100644 index 0000000000..ccd40c585b --- /dev/null +++ b/tests/jenkins/data/opensearch-2.2.0.yml @@ -0,0 +1,152 @@ +--- +schema-version: '1.0' +build: + name: OpenSearch + version: 2.2.0 +ci: + image: + name: opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2 + args: -e JAVA_HOME=/opt/java/openjdk-17 +components: + - name: OpenSearch + repository: https://github.com/opensearch-project/OpenSearch.git + ref: '2.2' + checks: + - gradle:publish + - gradle:properties:version + - name: common-utils + repository: https://github.com/opensearch-project/common-utils.git + ref: '2.x' + platforms: + - linux + checks: + - gradle:publish + - gradle:properties:version + - name: job-scheduler + repository: https://github.com/opensearch-project/job-scheduler.git + ref: '2.2' + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: ml-commons + repository: https://github.com/opensearch-project/ml-commons.git + ref: '2.2' + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version: opensearch-ml-plugin + - name: performance-analyzer + repository: https://github.com/opensearch-project/performance-analyzer.git + ref: '2.2' + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: security + repository: https://github.com/opensearch-project/security.git + ref: '2.2' + platforms: + - linux + - name: geospatial + repository: https://github.com/opensearch-project/geospatial.git + ref: '2.2' + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: k-NN + repository: https://github.com/opensearch-project/k-NN.git + ref: '2.2' + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: cross-cluster-replication + repository: https://github.com/opensearch-project/cross-cluster-replication.git + ref: '2.2' + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: notifications-core + repository: https://github.com/opensearch-project/notifications.git + ref: '2.2' + platforms: + - linux + working_directory: notifications + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version: opensearch-notifications-core + - name: notifications + repository: https://github.com/opensearch-project/notifications.git + ref: '2.2' + platforms: + - linux + working_directory: notifications + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version: notifications + - name: anomaly-detection + repository: https://github.com/opensearch-project/anomaly-detection.git + ref: '2.2' + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: asynchronous-search + repository: https://github.com/opensearch-project/asynchronous-search.git + ref: '2.2' + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: alerting + repository: https://github.com/opensearch-project/alerting.git + ref: '2.2' + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version: alerting + - name: index-management + repository: https://github.com/opensearch-project/index-management.git + ref: '2.2' + platforms: + - linux + checks: + - gradle:properties:version + - name: sql + repository: https://github.com/opensearch-project/sql.git + ref: '2.2' + platforms: + - linux + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version: opensearch-sql-plugin + - name: opensearch-observability + repository: https://github.com/opensearch-project/observability + ref: '2.2' + platforms: + - linux + working_directory: opensearch-observability + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version + - name: dashboards-reports + repository: https://github.com/opensearch-project/dashboards-reports.git + ref: '2.2' + platforms: + - linux + working_directory: reports-scheduler + checks: + - gradle:properties:version + - gradle:dependencies:opensearch.version diff --git a/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile new file mode 100644 index 0000000000..deebdd4bae --- /dev/null +++ b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile @@ -0,0 +1,47 @@ +/* + * SPDX-License-Identifier: Apache-2.0 + * + * The OpenSearch Contributors require contributions made to + * this file be licensed under the Apache-2.0 license or a + * compatible open source license. + */ + +pipeline { + agent none + stages { + stage('Initialize the buildInfoYaml report') { + steps { + script { + buildInfoYaml( + componentName: "", + inputManifest: "tests/jenkins/data/opensearch-2.2.0.yml", + outputFile: "tests/jenkins/data/buildInfo.yml", + status: "NOT_STARTED", + stage: "START" + ) + buildInfoYaml( + componentName: "", + inputManifest: "tests/jenkins/data/buildInfo.yml", + outputFile: "tests/jenkins/data/buildInfo.yml", + status: "SUCCESS", + stage: "x64_tar" + ) + buildInfoYaml( + componentName: "", + inputManifest: "tests/jenkins/data/buildInfo.yml", + outputFile: "tests/jenkins/data/buildInfo.yml", + status: "6", + stage: "integ_test_x64" + ) + buildInfoYaml( + componentName: "", + inputManifest: "tests/jenkins/data/buildInfo.yml", + outputFile: "tests/jenkins/data/buildInfo.yml", + status: "SUCCESS", + stage: "COMPLETE" + ) + } + } + } + } +} diff --git a/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt new file mode 100644 index 0000000000..856250467d --- /dev/null +++ b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt @@ -0,0 +1,96 @@ + BuildInfoYaml_Jenkinsfile.run() + BuildInfoYaml_Jenkinsfile.pipeline(groovy.lang.Closure) + BuildInfoYaml_Jenkinsfile.echo(Executing on agent [label:none]) + BuildInfoYaml_Jenkinsfile.stage(Initialize the buildInfoYaml report, groovy.lang.Closure) + BuildInfoYaml_Jenkinsfile.script(groovy.lang.Closure) + BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/opensearch-2.2.0.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=NOT_STARTED, stage=START}) + buildInfoYaml.readYaml({file=tests/jenkins/data/opensearch-2.2.0.yml}) + buildInfoYaml.echo(The status is NOT_STARTED) + buildInfoYaml.echo(Components is ) + buildInfoYaml.echo(Components parameter is null) + buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) + buildInfoYaml.echo(Initiate the buildInfo yaml file.) + buildInfoYaml.dir(OpenSearch, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/OpenSearch.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(common-utils, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.x}], userRemoteConfigs=[{url=https://github.com/opensearch-project/common-utils.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(job-scheduler, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/job-scheduler.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(ml-commons, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/ml-commons.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(performance-analyzer, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/performance-analyzer.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(security, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/security.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(geospatial, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/geospatial.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(k-NN, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/k-NN.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(cross-cluster-replication, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/cross-cluster-replication.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(notifications-core, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/notifications.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(notifications, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/notifications.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(anomaly-detection, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/anomaly-detection.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(asynchronous-search, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/asynchronous-search.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(alerting, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/alerting.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(index-management, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/index-management.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(sql, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/sql.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(opensearch-observability, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/observability}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.dir(dashboards-reports, groovy.lang.Closure) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/dashboards-reports.git}]}) + buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) + buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=IN_PROGRESS, number=123}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED}}, overwrite=true}) + buildInfoYaml.sh(cat tests/jenkins/data/buildInfo.yml) + BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=SUCCESS, stage=x64_tar}) + buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) + buildInfoYaml.echo(The status is SUCCESS) + buildInfoYaml.echo(Components is ) + buildInfoYaml.echo(Components parameter is null) + buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) + buildInfoYaml.echo(stage is x64_tar) + buildInfoYaml.echo(status is SUCCESS) + buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=SUCCESS, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=154442, startTimestamp=1660345758679}}, overwrite=true}) + buildInfoYaml.sh(cat tests/jenkins/data/buildInfo.yml) + BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=6, stage=integ_test_x64}) + buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) + buildInfoYaml.echo(The status is 6) + buildInfoYaml.echo(Components is ) + buildInfoYaml.echo(Components parameter is null) + buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) + buildInfoYaml.echo(stage is integ_test_x64) + buildInfoYaml.echo(status is 6) + buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=6, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=154442, startTimestamp=1660345758679}}, overwrite=true}) + buildInfoYaml.sh(cat tests/jenkins/data/buildInfo.yml) + BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=SUCCESS, stage=COMPLETE}) + buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) + buildInfoYaml.echo(The status is SUCCESS) + buildInfoYaml.echo(Components is ) + buildInfoYaml.echo(Components parameter is null) + buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) + buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=1, startTimestamp=1}}, overwrite=true}) + buildInfoYaml.sh(cat tests/jenkins/data/buildInfo.yml) diff --git a/tests/jenkins/jobs/GetRepositoryCommit_Jenkinsfile b/tests/jenkins/jobs/GetRepositoryCommit_Jenkinsfile deleted file mode 100644 index f50c4200d2..0000000000 --- a/tests/jenkins/jobs/GetRepositoryCommit_Jenkinsfile +++ /dev/null @@ -1,24 +0,0 @@ -/* - * SPDX-License-Identifier: Apache-2.0 - * - * The OpenSearch Contributors require contributions made to - * this file be licensed under the Apache-2.0 license or a - * compatible open source license. - */ - -pipeline { - agent none - stages { - stage('get repository commits') { - steps { - script { - getRepositoryCommit( - componentName: "", - inputManifest: "tests/jenkins/data/opensearch-2.0.0.yml", - outputFile: "commits.yml" - ) - } - } - } - } -} diff --git a/tests/jenkins/jobs/GetRepositoryCommit_Jenkinsfile.txt b/tests/jenkins/jobs/GetRepositoryCommit_Jenkinsfile.txt deleted file mode 100644 index c5fef559db..0000000000 --- a/tests/jenkins/jobs/GetRepositoryCommit_Jenkinsfile.txt +++ /dev/null @@ -1,62 +0,0 @@ - GetRepositoryCommit_Jenkinsfile.run() - GetRepositoryCommit_Jenkinsfile.pipeline(groovy.lang.Closure) - GetRepositoryCommit_Jenkinsfile.echo(Executing on agent [label:none]) - GetRepositoryCommit_Jenkinsfile.stage(get repository commits, groovy.lang.Closure) - GetRepositoryCommit_Jenkinsfile.script(groovy.lang.Closure) - GetRepositoryCommit_Jenkinsfile.getRepositoryCommit({componentName=, inputManifest=tests/jenkins/data/opensearch-2.0.0.yml, outputFile=commits.yml}) - getRepositoryCommit.sh(#!/bin/bash - - set +x - set -e - - COMPONENT_LIST=() - COMPONENT_URL_LIST=() - COMPONENT_REF_LIST=() - - mkdir -p commits; cd commits - CURR_DIR=`pwd` - OUTPUT_FILE=commits.yml - cp -v /tmp/workspace/tests/jenkins/data/opensearch-2.0.0.yml /tmp/workspace/$OUTPUT_FILE - - if [ -z "" ]; then - echo "Component list not specified so search the entire input manifest: /tmp/workspace/tests/jenkins/data/opensearch-2.0.0.yml" - read -r -a COMPONENT_LIST <<< `yq e '.components[].name' /tmp/workspace/tests/jenkins/data/opensearch-2.0.0.yml | tr ' -' ' '` - echo "Component list: ${COMPONENT_LIST[@]}" - else - echo "Specified component list: " - for comp in ; do - comp_temp=`yq e ".components[] | select(.name == \"$comp\") | .name" /tmp/workspace/tests/jenkins/data/opensearch-2.0.0.yml | tr ' -' ' ' | head -n 1` - if [ -z "$comp_temp" ] || [ "$comp_temp" = "null" ]; then - echo "ERROR: $comp does not exist in manifest /tmp/workspace/tests/jenkins/data/opensearch-2.0.0.yml" - exit 1 - fi - done - read -r -a COMPONENT_LIST <<< "" - echo "Component list: ${COMPONENT_LIST[@]}" - fi - - for entry in ${COMPONENT_LIST[@]}; do - COMPONENT_URL_LIST+=(`yq e ".components[] | select(.name == \"$entry\") | .repository" /tmp/workspace/tests/jenkins/data/opensearch-2.0.0.yml | tr ' -' ' ' | head -n 1`) - COMPONENT_REF_LIST+=(`yq e ".components[] | select(.name == \"$entry\") | .ref" /tmp/workspace/tests/jenkins/data/opensearch-2.0.0.yml | tr ' -' ' ' | head -n 1`) - done - - echo "Component url list: ${COMPONENT_URL_LIST[@]}" - echo "Component ref list: ${COMPONENT_REF_LIST[@]}" - - for index in ${!COMPONENT_LIST[@]}; do - cd $CURR_DIR - mkdir -p ${COMPONENT_LIST[$index]} - cd ${COMPONENT_LIST[$index]} - git init -q - git remote add origin ${COMPONENT_URL_LIST[$index]} - git fetch --depth 1 origin ${COMPONENT_REF_LIST[$index]} - git checkout -q FETCH_HEAD - REAL_REF=`git rev-parse HEAD` - echo $REAL_REF - yq -i ".components |= map(select(.name == \"${COMPONENT_LIST[$index]}\").ref=\"$REAL_REF\")" /tmp/workspace/$OUTPUT_FILE - done - ) diff --git a/tests/jenkins/lib-testers/BuildInfoYamlLibTester.groovy b/tests/jenkins/lib-testers/BuildInfoYamlLibTester.groovy new file mode 100644 index 0000000000..5b4870ac40 --- /dev/null +++ b/tests/jenkins/lib-testers/BuildInfoYamlLibTester.groovy @@ -0,0 +1,46 @@ +import static org.hamcrest.CoreMatchers.notNullValue +import static org.hamcrest.MatcherAssert.assertThat + + +class BuildInfoYamlLibTester extends LibFunctionTester { + + private String componentName + private String inputManifest + private String outputFile + private String status + private String stage + + public BuildInfoYamlLibTester(componentName, inputManifest, outputFile, status, stage){ + this.componentName = componentName + this.inputManifest = inputManifest + this.outputFile = outputFile + this.status = status + this.stage = stage + } + + void configure(helper, binding) { + binding.setVariable('BUILD_NUMBER', '123') + helper.registerAllowedMethod("writeYaml", [Map.class], {c -> }) + helper.addShMock("git rev-parse HEAD") { script -> + return [stdout: "75eccfe03b4e58ede1a69eb6008196c44e7008c6", exitValue: 0] + } + } + + void parameterInvariantsAssertions(call) { + assertThat(call.args.inputManifest.first(), notNullValue()) + assertThat(call.args.outputFile.first(), notNullValue()) + assertThat(call.args.status.first(), notNullValue()) + assertThat(call.args.stage.first(), notNullValue()) + } + + boolean expectedParametersMatcher(call) { + return call.args.inputManifest.first().toString().equals(this.inputManifest) + && call.args.outputFile.first().toString().equals(this.outputFile) + && call.args.status.first().toString().equals(this.status) + && call.args.stage.first().toString().equals(this.stage) + } + + String libFunctionName() { + return 'buildInfoYaml' + } +} diff --git a/tests/jenkins/lib-testers/GetRepositoryCommitLibTester.groovy b/tests/jenkins/lib-testers/GetRepositoryCommitLibTester.groovy deleted file mode 100644 index 2bb4fa6e54..0000000000 --- a/tests/jenkins/lib-testers/GetRepositoryCommitLibTester.groovy +++ /dev/null @@ -1,34 +0,0 @@ -import static org.hamcrest.CoreMatchers.notNullValue -import static org.hamcrest.MatcherAssert.assertThat - - -class GetRepositoryCommitLibTester extends LibFunctionTester { - - private String componentName - private String inputManifest - private String outputFile - - public GetRepositoryCommitLibTester(componentName, inputManifest, outputFile){ - this.componentName = componentName - this.inputManifest = inputManifest - this.outputFile = outputFile - } - - void configure(helper, binding) { - // N/A - } - - void parameterInvariantsAssertions(call) { - assertThat(call.args.inputManifest.first(), notNullValue()) - assertThat(call.args.outputFile.first(), notNullValue()) - } - - boolean expectedParametersMatcher(call) { - return call.args.inputManifest.first().toString().equals(this.inputManifest) - && call.args.outputFile.first().toString().equals(this.outputFile) - } - - String libFunctionName() { - return 'getRepositoryCommit' - } -} diff --git a/vars/buildInfoYaml.groovy b/vars/buildInfoYaml.groovy new file mode 100644 index 0000000000..cc441be34b --- /dev/null +++ b/vars/buildInfoYaml.groovy @@ -0,0 +1,69 @@ +def call(Map args = [:]) { + + def inputManifest = readYaml(file: args.inputManifest) + def outputFile = args.outputFile + def components = args.componentName + def componentsList = [] + def status = args.status + echo("The status is $status") + echo("Components is $components") + if (!components.isEmpty()) { + echo ("Components parameter is not null") + for (component in components.split(" ")) { + componentsList.add(component.trim()) + } + } else { + echo ("Components parameter is null") + inputManifest.components.each { component -> + componentsList.add(component.name) + } + } + echo (componentsList.toString()) + if (args.stage == "START") { + echo("Initiate the buildInfo yaml file.") + inputManifest.build.status = "IN_PROGRESS" + inputManifest.build.number = "${BUILD_NUMBER}" + inputManifest.results = [:] + inputManifest.results.integ_test_x64 = status + inputManifest.results.bwc_test_x64 = status + inputManifest.results.integ_test_arm64 = status + inputManifest.results.bwc_test_arm64 = status + inputManifest.results.x64_tar = status + inputManifest.results.arm64_tar = status + inputManifest.results.x64_rpm = status + inputManifest.results.arm64_rpm = status + inputManifest.components.each { component -> + if (componentsList.contains(component.name)) { + // Convert ref from branch to commit + dir (component.name) { + checkout([$class: 'GitSCM', branches: [[name: component.ref]], + userRemoteConfigs: [[url: component.repository]]]) + def commitID = sh ( + script: "git rev-parse HEAD", + returnStdout: true + ).trim() + component.ref = commitID + } + } + } + } + else if (args.stage == "x64_tar" || args.stage == "x64_rpm" || args.stage == "arm64_tar" || args.stage == "arm64_rpm") { + stageField = args.stage + echo("stage is $stageField") + echo("status is $status") + inputManifest.results.("$stageField".toString()) = "$status" + } + else if (args.stage == "integ_test_x64" || args.stage == "integ_test_arm64" || args.stage == "bwc_test_x64" || args.stage == "bwc_test_arm64") { + stageField = args.stage + echo("stage is $stageField") + echo("status is $status") + inputManifest.results.("$stageField".toString()) = "$status" + } + else if (args.stage == "COMPLETE") { + inputManifest.build.status = status + inputManifest.results.duration = currentBuild.duration + inputManifest.results.startTimestamp = currentBuild.startTimeInMillis + } + writeYaml(file: outputFile, data: inputManifest, overwrite: true) + sh ("cat $outputFile") +} diff --git a/vars/getRepositoryCommit.groovy b/vars/getRepositoryCommit.groovy deleted file mode 100644 index c93998eb3f..0000000000 --- a/vars/getRepositoryCommit.groovy +++ /dev/null @@ -1,55 +0,0 @@ -void call(Map args = [:]) { - - sh """#!/bin/bash - - set +x - set -e - - COMPONENT_LIST=() - COMPONENT_URL_LIST=() - COMPONENT_REF_LIST=() - - mkdir -p commits; cd commits - CURR_DIR=`pwd` - OUTPUT_FILE=${args.outputFile} - cp -v ${WORKSPACE}/${args.inputManifest} ${WORKSPACE}/\$OUTPUT_FILE - - if [ -z "${args.componentName}" ]; then - echo "Component list not specified so search the entire input manifest: ${WORKSPACE}/${args.inputManifest}" - read -r -a COMPONENT_LIST <<< `yq e '.components[].name' ${WORKSPACE}/${args.inputManifest} | tr '\n' ' '` - echo "Component list: \${COMPONENT_LIST[@]}" - else - echo "Specified component list: ${args.componentName}" - for comp in ${args.componentName}; do - comp_temp=`yq e ".components[] | select(.name == \\"\$comp\\") | .name" ${WORKSPACE}/${args.inputManifest} | tr '\n' ' ' | head -n 1` - if [ -z "\$comp_temp" ] || [ "\$comp_temp" = "null" ]; then - echo "ERROR: \$comp does not exist in manifest ${WORKSPACE}/${args.inputManifest}" - exit 1 - fi - done - read -r -a COMPONENT_LIST <<< "${args.componentName}" - echo "Component list: \${COMPONENT_LIST[@]}" - fi - - for entry in \${COMPONENT_LIST[@]}; do - COMPONENT_URL_LIST+=(`yq e ".components[] | select(.name == \\"\$entry\\") | .repository" ${WORKSPACE}/${args.inputManifest} | tr '\n' ' ' | head -n 1`) - COMPONENT_REF_LIST+=(`yq e ".components[] | select(.name == \\"\$entry\\") | .ref" ${WORKSPACE}/${args.inputManifest} | tr '\n' ' ' | head -n 1`) - done - - echo "Component url list: \${COMPONENT_URL_LIST[@]}" - echo "Component ref list: \${COMPONENT_REF_LIST[@]}" - - for index in \${!COMPONENT_LIST[@]}; do - cd \$CURR_DIR - mkdir -p \${COMPONENT_LIST[\$index]} - cd \${COMPONENT_LIST[\$index]} - git init -q - git remote add origin \${COMPONENT_URL_LIST[\$index]} - git fetch --depth 1 origin \${COMPONENT_REF_LIST[\$index]} - git checkout -q FETCH_HEAD - REAL_REF=`git rev-parse HEAD` - echo \$REAL_REF - yq -i ".components |= map(select(.name == \\"\${COMPONENT_LIST[\$index]}\\").ref=\\"\$REAL_REF\\")" ${WORKSPACE}/\$OUTPUT_FILE - done - """ -} From 25c91aba0f653c023d82a947a27371a2fefc3e08 Mon Sep 17 00:00:00 2001 From: Zelin Hao Date: Wed, 17 Aug 2022 17:11:01 -0700 Subject: [PATCH 2/6] Some simplify Signed-off-by: Zelin Hao --- tests/jenkins/data/BuildInfo.yml | 3 ++- vars/buildInfoYaml.groovy | 29 +++++++---------------------- 2 files changed, 9 insertions(+), 23 deletions(-) diff --git a/tests/jenkins/data/BuildInfo.yml b/tests/jenkins/data/BuildInfo.yml index 5c585c14fc..17a509a42f 100644 --- a/tests/jenkins/data/BuildInfo.yml +++ b/tests/jenkins/data/BuildInfo.yml @@ -1,4 +1,5 @@ ----schema-version: '1.0' +--- +schema-version: '1.0' build: name: OpenSearch version: 2.2.0 diff --git a/vars/buildInfoYaml.groovy b/vars/buildInfoYaml.groovy index cc441be34b..df337ed3dd 100644 --- a/vars/buildInfoYaml.groovy +++ b/vars/buildInfoYaml.groovy @@ -19,26 +19,19 @@ def call(Map args = [:]) { } } echo (componentsList.toString()) + if (args.stage == "START") { echo("Initiate the buildInfo yaml file.") inputManifest.build.status = "IN_PROGRESS" inputManifest.build.number = "${BUILD_NUMBER}" inputManifest.results = [:] - inputManifest.results.integ_test_x64 = status - inputManifest.results.bwc_test_x64 = status - inputManifest.results.integ_test_arm64 = status - inputManifest.results.bwc_test_arm64 = status - inputManifest.results.x64_tar = status - inputManifest.results.arm64_tar = status - inputManifest.results.x64_rpm = status - inputManifest.results.arm64_rpm = status inputManifest.components.each { component -> if (componentsList.contains(component.name)) { // Convert ref from branch to commit - dir (component.name) { - checkout([$class: 'GitSCM', branches: [[name: component.ref]], + dir(component.name) { + checkout([$class : 'GitSCM', branches: [[name: component.ref]], userRemoteConfigs: [[url: component.repository]]]) - def commitID = sh ( + def commitID = sh( script: "git rev-parse HEAD", returnStdout: true ).trim() @@ -46,21 +39,13 @@ def call(Map args = [:]) { } } } - } - else if (args.stage == "x64_tar" || args.stage == "x64_rpm" || args.stage == "arm64_tar" || args.stage == "arm64_rpm") { - stageField = args.stage - echo("stage is $stageField") - echo("status is $status") - inputManifest.results.("$stageField".toString()) = "$status" - } - else if (args.stage == "integ_test_x64" || args.stage == "integ_test_arm64" || args.stage == "bwc_test_x64" || args.stage == "bwc_test_arm64") { + } else if (args.stage == "COMPLETE") { + inputManifest.build.status = status + } else { stageField = args.stage echo("stage is $stageField") echo("status is $status") inputManifest.results.("$stageField".toString()) = "$status" - } - else if (args.stage == "COMPLETE") { - inputManifest.build.status = status inputManifest.results.duration = currentBuild.duration inputManifest.results.startTimestamp = currentBuild.startTimeInMillis } From a48bbd87074c974408f0cff84c6014ccabfbd211 Mon Sep 17 00:00:00 2001 From: Zelin Hao Date: Fri, 19 Aug 2022 13:19:47 -0700 Subject: [PATCH 3/6] Update Signed-off-by: Zelin Hao --- .../jobs/BuildInfoYaml_Jenkinsfile.txt | 94 +++++++++---------- vars/buildInfoYaml.groovy | 2 +- 2 files changed, 48 insertions(+), 48 deletions(-) diff --git a/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt index 856250467d..cea7e117da 100644 --- a/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt +++ b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt @@ -10,87 +10,87 @@ buildInfoYaml.echo(Components parameter is null) buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) buildInfoYaml.echo(Initiate the buildInfo yaml file.) + buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=IN_PROGRESS, number=123}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=2.2, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=2.x, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=2.2, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=2.2, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=2.2, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=2.2, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=2.2, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={}}, overwrite=true}) + buildInfoYaml.sh(cat tests/jenkins/data/buildInfo.yml) + BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=SUCCESS, stage=x64_tar}) + buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) + buildInfoYaml.echo(The status is SUCCESS) + buildInfoYaml.echo(Components is ) + buildInfoYaml.echo(Components parameter is null) + buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) + buildInfoYaml.echo(stage is x64_tar) + buildInfoYaml.echo(status is SUCCESS) + buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=SUCCESS, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=1, startTimestamp=1}}, overwrite=true}) + buildInfoYaml.sh(cat tests/jenkins/data/buildInfo.yml) + BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=6, stage=integ_test_x64}) + buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) + buildInfoYaml.echo(The status is 6) + buildInfoYaml.echo(Components is ) + buildInfoYaml.echo(Components parameter is null) + buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) + buildInfoYaml.echo(stage is integ_test_x64) + buildInfoYaml.echo(status is 6) + buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=6, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=1, startTimestamp=1}}, overwrite=true}) + buildInfoYaml.sh(cat tests/jenkins/data/buildInfo.yml) + BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=SUCCESS, stage=COMPLETE}) + buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) + buildInfoYaml.echo(The status is SUCCESS) + buildInfoYaml.echo(Components is ) + buildInfoYaml.echo(Components parameter is null) + buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) buildInfoYaml.dir(OpenSearch, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/OpenSearch.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=b1017fa3b9a1c781d4f34ecee411e0cdf930a515}], userRemoteConfigs=[{url=https://github.com/opensearch-project/OpenSearch.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(common-utils, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.x}], userRemoteConfigs=[{url=https://github.com/opensearch-project/common-utils.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b}], userRemoteConfigs=[{url=https://github.com/opensearch-project/common-utils.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(job-scheduler, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/job-scheduler.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d}], userRemoteConfigs=[{url=https://github.com/opensearch-project/job-scheduler.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(ml-commons, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/ml-commons.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=a7d269500f8667fdd4cd4d582c7148a7e7fb557c}], userRemoteConfigs=[{url=https://github.com/opensearch-project/ml-commons.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(performance-analyzer, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/performance-analyzer.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=3a75d7d5a6302b3c9fd78fb7104f90689d407484}], userRemoteConfigs=[{url=https://github.com/opensearch-project/performance-analyzer.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(security, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/security.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=ff17b025d15793d600f4b31d6dd4bbde97030f39}], userRemoteConfigs=[{url=https://github.com/opensearch-project/security.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(geospatial, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/geospatial.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=a71475ab3b0de008ca352e290d99fb3b53f1a1c5}], userRemoteConfigs=[{url=https://github.com/opensearch-project/geospatial.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(k-NN, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/k-NN.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=53185a0f165ebe1f8c3e01fd80a867727ba3674f}], userRemoteConfigs=[{url=https://github.com/opensearch-project/k-NN.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(cross-cluster-replication, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/cross-cluster-replication.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=719634b60056e48e35cccba1f1ed3a0a43bb90e5}], userRemoteConfigs=[{url=https://github.com/opensearch-project/cross-cluster-replication.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(notifications-core, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/notifications.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=01b4aa8886b4bb8faabf482bf9f4baaa441015fe}], userRemoteConfigs=[{url=https://github.com/opensearch-project/notifications.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(notifications, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/notifications.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=01b4aa8886b4bb8faabf482bf9f4baaa441015fe}], userRemoteConfigs=[{url=https://github.com/opensearch-project/notifications.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(anomaly-detection, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/anomaly-detection.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=04f27418fe97110635b08dd986d77ce0ecc384ec}], userRemoteConfigs=[{url=https://github.com/opensearch-project/anomaly-detection.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(asynchronous-search, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/asynchronous-search.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=4f1f992c6bb134dab191042a87216f1616be8a27}], userRemoteConfigs=[{url=https://github.com/opensearch-project/asynchronous-search.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(alerting, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/alerting.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=b3d676f70b0df8df9cab0919a147ed395c568797}], userRemoteConfigs=[{url=https://github.com/opensearch-project/alerting.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(index-management, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/index-management.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d}], userRemoteConfigs=[{url=https://github.com/opensearch-project/index-management.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(sql, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/sql.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=454122d3c73dcf8944800720e2116fd6540d3b26}], userRemoteConfigs=[{url=https://github.com/opensearch-project/sql.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(opensearch-observability, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/observability}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=4055decd159c2cff401b43006f6ccba73e6f67b6}], userRemoteConfigs=[{url=https://github.com/opensearch-project/observability}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) buildInfoYaml.dir(dashboards-reports, groovy.lang.Closure) - buildInfoYaml.checkout({$class=GitSCM, branches=[{name=2.2}], userRemoteConfigs=[{url=https://github.com/opensearch-project/dashboards-reports.git}]}) + buildInfoYaml.checkout({$class=GitSCM, branches=[{name=1d3980ab2d93a89acd0a5716f575a222389b9e8d}], userRemoteConfigs=[{url=https://github.com/opensearch-project/dashboards-reports.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) - buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=IN_PROGRESS, number=123}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED}}, overwrite=true}) - buildInfoYaml.sh(cat tests/jenkins/data/buildInfo.yml) - BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=SUCCESS, stage=x64_tar}) - buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) - buildInfoYaml.echo(The status is SUCCESS) - buildInfoYaml.echo(Components is ) - buildInfoYaml.echo(Components parameter is null) - buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) - buildInfoYaml.echo(stage is x64_tar) - buildInfoYaml.echo(status is SUCCESS) - buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=SUCCESS, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=154442, startTimestamp=1660345758679}}, overwrite=true}) - buildInfoYaml.sh(cat tests/jenkins/data/buildInfo.yml) - BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=6, stage=integ_test_x64}) - buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) - buildInfoYaml.echo(The status is 6) - buildInfoYaml.echo(Components is ) - buildInfoYaml.echo(Components parameter is null) - buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) - buildInfoYaml.echo(stage is integ_test_x64) - buildInfoYaml.echo(status is 6) - buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=6, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=154442, startTimestamp=1660345758679}}, overwrite=true}) - buildInfoYaml.sh(cat tests/jenkins/data/buildInfo.yml) - BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=SUCCESS, stage=COMPLETE}) - buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) - buildInfoYaml.echo(The status is SUCCESS) - buildInfoYaml.echo(Components is ) - buildInfoYaml.echo(Components parameter is null) - buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) - buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=1, startTimestamp=1}}, overwrite=true}) + buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=154442, startTimestamp=1660345758679}}, overwrite=true}) buildInfoYaml.sh(cat tests/jenkins/data/buildInfo.yml) diff --git a/vars/buildInfoYaml.groovy b/vars/buildInfoYaml.groovy index df337ed3dd..d8a3fdf837 100644 --- a/vars/buildInfoYaml.groovy +++ b/vars/buildInfoYaml.groovy @@ -25,6 +25,7 @@ def call(Map args = [:]) { inputManifest.build.status = "IN_PROGRESS" inputManifest.build.number = "${BUILD_NUMBER}" inputManifest.results = [:] + } else if (args.stage == "COMPLETE") { inputManifest.components.each { component -> if (componentsList.contains(component.name)) { // Convert ref from branch to commit @@ -39,7 +40,6 @@ def call(Map args = [:]) { } } } - } else if (args.stage == "COMPLETE") { inputManifest.build.status = status } else { stageField = args.stage From 7ee3b437c27c7fb2f5fa18d56f25ad9f0015e4e6 Mon Sep 17 00:00:00 2001 From: Zelin Hao Date: Mon, 22 Aug 2022 14:20:58 -0700 Subject: [PATCH 4/6] Cut the scope and simplify Signed-off-by: Zelin Hao --- .../distribution-build.jenkinsfile | 115 +----------------- .../opensearch/distribution-build.jenkinsfile | 114 +---------------- .../jobs/BuildInfoYaml_Jenkinsfile.txt | 30 +++-- vars/buildInfoYaml.groovy | 36 +++--- 4 files changed, 49 insertions(+), 246 deletions(-) diff --git a/jenkins/opensearch-dashboards/distribution-build.jenkinsfile b/jenkins/opensearch-dashboards/distribution-build.jenkinsfile index 678542a683..106b3bcb24 100644 --- a/jenkins/opensearch-dashboards/distribution-build.jenkinsfile +++ b/jenkins/opensearch-dashboards/distribution-build.jenkinsfile @@ -65,7 +65,7 @@ pipeline { } } } - stage('Initialize the buildInfoYaml report') { + stage('Initialize the job info yaml report') { agent { docker { label AGENT_X64 @@ -78,11 +78,9 @@ pipeline { buildInfoYaml( componentName: COMPONENT_NAME, inputManifest: "manifests/$INPUT_MANIFEST", - outputFile: "buildInfo.yml", status: "NOT_STARTED", stage: "START" ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" } } post { @@ -134,15 +132,11 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_X64) ] - unstash "buildInfo_manifest" buildInfoYaml( componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", status: integTestResults.getId(), stage: "integ_test_x64" ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" env.ARTIFACT_URL_X64_TAR_INTEG_TEST_RESULT = createTestResultsMessage( @@ -166,15 +160,11 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_X64) ] - unstash "buildInfo_manifest" buildInfoYaml( componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", status: bwcTestResults.getId(), stage: "bwc_test_x64" ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" env.ARTIFACT_URL_X64_TAR_BWC_TEST_RESULT = createTestResultsMessage( testType: "BWC Tests (x64, tar)", @@ -199,28 +189,6 @@ pipeline { postCleanup() } } - success { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "SUCCESS", - stage: "x64_tar" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } - failure { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "FAILURE", - stage: "x64_tar" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } } } stage('build-and-test-linux-x64-rpm') { @@ -298,28 +266,6 @@ pipeline { } } post { - success { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "SUCCESS", - stage: "x64_rpm" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } - failure { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "FAILURE", - stage: "x64_rpm" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } always { script { lib.jenkins.Messages.new(this).add( @@ -406,16 +352,11 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_ARM64) ] - unstash "buildInfo_manifest" buildInfoYaml( componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", status: integTestResults.getId(), stage: "integ_test_arm64" ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - env.ARTIFACT_URL_ARM64_TAR_INTEG_TEST_RESULT = createTestResultsMessage( testType: "Integ Tests (arm64, tar)", @@ -438,15 +379,11 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_ARM64) ] - unstash "buildInfo_manifest" buildInfoYaml( componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", status: bwcTestResults.getId(), stage: "bwc_test_arm64" ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" env.ARTIFACT_URL_ARM64_TAR_BWC_TEST_RESULT = createTestResultsMessage( testType: "BWC Tests (arm64, tar)", @@ -471,28 +408,6 @@ pipeline { postCleanup() } } - success { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "SUCCESS", - stage: "arm64_tar" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } - failure { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "FAILURE", - stage: "arm64_tar" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } } } } @@ -571,28 +486,6 @@ pipeline { } } post { - success { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "SUCCESS", - stage: "arm64_rpm" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } - failure { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "FAILURE", - stage: "arm64_rpm" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } always { script { lib.jenkins.Messages.new(this).add( @@ -662,15 +555,13 @@ pipeline { always { node(AGENT_X64) { script { - unstash "buildInfo_manifest" buildInfoYaml( componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", status: currentBuild.result, stage: "COMPLETE" ) - archiveArtifacts artifacts: 'buildInfo.yml' + unstash "job_yml" + archiveArtifacts artifacts: 'job.yml' postCleanup() } } diff --git a/jenkins/opensearch/distribution-build.jenkinsfile b/jenkins/opensearch/distribution-build.jenkinsfile index 8fb694efb9..e1543f162f 100644 --- a/jenkins/opensearch/distribution-build.jenkinsfile +++ b/jenkins/opensearch/distribution-build.jenkinsfile @@ -65,7 +65,7 @@ pipeline { } } } - stage('Initialize the buildInfoYaml report') { + stage('Initialize the job info yaml report') { agent { docker { label AGENT_X64 @@ -78,11 +78,9 @@ pipeline { buildInfoYaml( componentName: COMPONENT_NAME, inputManifest: "manifests/$INPUT_MANIFEST", - outputFile: "buildInfo.yml", status: "NOT_STARTED", stage: "START" ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" } } post { @@ -235,15 +233,11 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_X64) ] - unstash "buildInfo_manifest" buildInfoYaml( componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", status: integTestResults.getId(), stage: "integ_test_x64" ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" env.ARTIFACT_URL_X64_TAR_INTEG_TEST_RESULT = createTestResultsMessage( testType: "Integ Tests (x64, tar)", @@ -266,15 +260,11 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_X64) ] - unstash "buildInfo_manifest" buildInfoYaml( componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", status: bwcTestResults.getId(), stage: "bwc_test_x64" ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" env.ARTIFACT_URL_X64_TAR_BWC_TEST_RESULT = createTestResultsMessage( testType: "BWC Tests (x64, tar)", @@ -299,28 +289,6 @@ pipeline { postCleanup() } } - success { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "SUCCESS", - stage: "x64_tar" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } - failure { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "FAILURE", - stage: "x64_tar" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } } } stage('build-and-test-x64-rpm') { @@ -398,28 +366,6 @@ pipeline { } } post { - success { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "SUCCESS", - stage: "x64_rpm" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } - failure { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "FAILURE", - stage: "x64_rpm" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } always { script { lib.jenkins.Messages.new(this).add( @@ -473,15 +419,11 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_ARM64) ] - unstash "buildInfo_manifest" buildInfoYaml( componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", status: integTestResults.getId(), stage: "integ_test_arm64" ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" env.ARTIFACT_URL_ARM64_TAR_INTEG_TEST_RESULT = createTestResultsMessage( testType: "Integ Tests (arm64, tar)", @@ -504,15 +446,11 @@ pipeline { string(name: 'AGENT_LABEL', value: AGENT_ARM64) ] - unstash "buildInfo_manifest" buildInfoYaml( componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", status: bwcTestResults.getId(), stage: "bwc_test_arm64" ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" env.ARTIFACT_URL_ARM64_TAR_BWC_TEST_RESULT = createTestResultsMessage( testType: "BWC Tests (arm64, tar)", @@ -537,28 +475,6 @@ pipeline { postCleanup() } } - success { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "SUCCESS", - stage: "arm64_tar" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } - failure { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "FAILURE", - stage: "arm64_tar" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } } } stage('build-and-test-arm64-rpm') { @@ -636,28 +552,6 @@ pipeline { } } post { - success { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "SUCCESS", - stage: "arm64_rpm" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } - failure { - unstash "buildInfo_manifest" - buildInfoYaml( - componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", - status: "FAILURE", - stage: "arm64_rpm" - ) - stash includes: "buildInfo.yml", name: "buildInfo_manifest" - } always { script { lib.jenkins.Messages.new(this).add( @@ -727,15 +621,13 @@ pipeline { always { node(AGENT_X64) { script { - unstash "buildInfo_manifest" buildInfoYaml( componentName: COMPONENT_NAME, - inputManifest: "buildInfo.yml", - outputFile: "buildInfo.yml", status: currentBuild.result, stage: "COMPLETE" ) - archiveArtifacts artifacts: 'buildInfo.yml' + unstash "job_yml" + archiveArtifacts artifacts: 'job.yml' postCleanup() } } diff --git a/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt index cea7e117da..ac8444dd14 100644 --- a/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt +++ b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt @@ -4,15 +4,20 @@ BuildInfoYaml_Jenkinsfile.stage(Initialize the buildInfoYaml report, groovy.lang.Closure) BuildInfoYaml_Jenkinsfile.script(groovy.lang.Closure) BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/opensearch-2.2.0.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=NOT_STARTED, stage=START}) + buildInfoYaml.unstash(job_yml) + buildInfoYaml.echo(No job.yml exists in stashed. Please make sure inputManifest parameter is passed.) buildInfoYaml.readYaml({file=tests/jenkins/data/opensearch-2.2.0.yml}) buildInfoYaml.echo(The status is NOT_STARTED) buildInfoYaml.echo(Components is ) buildInfoYaml.echo(Components parameter is null) buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) - buildInfoYaml.echo(Initiate the buildInfo yaml file.) - buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=IN_PROGRESS, number=123}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=2.2, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=2.x, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=2.2, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=2.2, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=2.2, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=2.2, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=2.2, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={}}, overwrite=true}) - buildInfoYaml.sh(cat tests/jenkins/data/buildInfo.yml) + buildInfoYaml.echo(Initiate the job info yaml file.) + buildInfoYaml.writeYaml({file=job.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=IN_PROGRESS, number=123}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=2.2, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=2.x, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=2.2, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=2.2, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=2.2, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=2.2, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=2.2, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={}}, overwrite=true}) + buildInfoYaml.sh(cat job.yml) + buildInfoYaml.stash({includes=job.yml, name=job_yml}) BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=SUCCESS, stage=x64_tar}) + buildInfoYaml.unstash(job_yml) + buildInfoYaml.echo(No job.yml exists in stashed. Please make sure inputManifest parameter is passed.) buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) buildInfoYaml.echo(The status is SUCCESS) buildInfoYaml.echo(Components is ) @@ -20,9 +25,12 @@ buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) buildInfoYaml.echo(stage is x64_tar) buildInfoYaml.echo(status is SUCCESS) - buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=SUCCESS, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=1, startTimestamp=1}}, overwrite=true}) - buildInfoYaml.sh(cat tests/jenkins/data/buildInfo.yml) + buildInfoYaml.writeYaml({file=job.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=SUCCESS, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=1, startTimestamp=1}}, overwrite=true}) + buildInfoYaml.sh(cat job.yml) + buildInfoYaml.stash({includes=job.yml, name=job_yml}) BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=6, stage=integ_test_x64}) + buildInfoYaml.unstash(job_yml) + buildInfoYaml.echo(No job.yml exists in stashed. Please make sure inputManifest parameter is passed.) buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) buildInfoYaml.echo(The status is 6) buildInfoYaml.echo(Components is ) @@ -30,9 +38,12 @@ buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) buildInfoYaml.echo(stage is integ_test_x64) buildInfoYaml.echo(status is 6) - buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=6, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=1, startTimestamp=1}}, overwrite=true}) - buildInfoYaml.sh(cat tests/jenkins/data/buildInfo.yml) + buildInfoYaml.writeYaml({file=job.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=6, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=1, startTimestamp=1}}, overwrite=true}) + buildInfoYaml.sh(cat job.yml) + buildInfoYaml.stash({includes=job.yml, name=job_yml}) BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=SUCCESS, stage=COMPLETE}) + buildInfoYaml.unstash(job_yml) + buildInfoYaml.echo(No job.yml exists in stashed. Please make sure inputManifest parameter is passed.) buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) buildInfoYaml.echo(The status is SUCCESS) buildInfoYaml.echo(Components is ) @@ -92,5 +103,6 @@ buildInfoYaml.dir(dashboards-reports, groovy.lang.Closure) buildInfoYaml.checkout({$class=GitSCM, branches=[{name=1d3980ab2d93a89acd0a5716f575a222389b9e8d}], userRemoteConfigs=[{url=https://github.com/opensearch-project/dashboards-reports.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) - buildInfoYaml.writeYaml({file=tests/jenkins/data/buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=154442, startTimestamp=1660345758679}}, overwrite=true}) - buildInfoYaml.sh(cat tests/jenkins/data/buildInfo.yml) + buildInfoYaml.writeYaml({file=job.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=154442, startTimestamp=1660345758679}}, overwrite=true}) + buildInfoYaml.sh(cat job.yml) + buildInfoYaml.stash({includes=job.yml, name=job_yml}) diff --git a/vars/buildInfoYaml.groovy b/vars/buildInfoYaml.groovy index d8a3fdf837..4769793ad1 100644 --- a/vars/buildInfoYaml.groovy +++ b/vars/buildInfoYaml.groovy @@ -1,7 +1,14 @@ def call(Map args = [:]) { - def inputManifest = readYaml(file: args.inputManifest) - def outputFile = args.outputFile + try { + unstash "job_yml" + } catch(Exception ex) { + echo("No job.yml exists in stashed. Please make sure inputManifest parameter is passed.") + } + + def inputManifest = args.inputManifest ?: "job.yml" + def sourceyml = readYaml(file: inputManifest) + def outputyml = args.outputyml ?: "job.yml" def components = args.componentName def componentsList = [] def status = args.status @@ -14,19 +21,19 @@ def call(Map args = [:]) { } } else { echo ("Components parameter is null") - inputManifest.components.each { component -> + sourceyml.components.each { component -> componentsList.add(component.name) } } echo (componentsList.toString()) if (args.stage == "START") { - echo("Initiate the buildInfo yaml file.") - inputManifest.build.status = "IN_PROGRESS" - inputManifest.build.number = "${BUILD_NUMBER}" - inputManifest.results = [:] + echo("Initiate the job info yaml file.") + sourceyml.build.status = "IN_PROGRESS" + sourceyml.build.number = "${BUILD_NUMBER}" + sourceyml.results = [:] } else if (args.stage == "COMPLETE") { - inputManifest.components.each { component -> + sourceyml.components.each { component -> if (componentsList.contains(component.name)) { // Convert ref from branch to commit dir(component.name) { @@ -40,15 +47,16 @@ def call(Map args = [:]) { } } } - inputManifest.build.status = status + sourceyml.build.status = status } else { stageField = args.stage echo("stage is $stageField") echo("status is $status") - inputManifest.results.("$stageField".toString()) = "$status" - inputManifest.results.duration = currentBuild.duration - inputManifest.results.startTimestamp = currentBuild.startTimeInMillis + sourceyml.results.("$stageField".toString()) = status + sourceyml.results.duration = currentBuild.duration + sourceyml.results.startTimestamp = currentBuild.startTimeInMillis } - writeYaml(file: outputFile, data: inputManifest, overwrite: true) - sh ("cat $outputFile") + writeYaml(file: outputyml, data: sourceyml, overwrite: true) + sh ("cat $outputyml") + stash includes: "job.yml", name: "job_yml" } From cb07cf75ee40a821bb32afb8c43b921d50b0164d Mon Sep 17 00:00:00 2001 From: Zelin Hao Date: Mon, 22 Aug 2022 14:51:58 -0700 Subject: [PATCH 5/6] Fix naming Signed-off-by: Zelin Hao --- tests/jenkins/TestBuildInfoYaml.groovy | 2 +- tests/jenkins/data/{BuildInfo.yml => job.yml} | 0 tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile | 14 +++++++------- .../jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt | 18 +++++++++--------- vars/buildInfoYaml.groovy | 6 +++--- 5 files changed, 20 insertions(+), 20 deletions(-) rename tests/jenkins/data/{BuildInfo.yml => job.yml} (100%) diff --git a/tests/jenkins/TestBuildInfoYaml.groovy b/tests/jenkins/TestBuildInfoYaml.groovy index fe364c3a3b..c4c3c85bb2 100644 --- a/tests/jenkins/TestBuildInfoYaml.groovy +++ b/tests/jenkins/TestBuildInfoYaml.groovy @@ -18,7 +18,7 @@ class TestBuildInfoYaml extends BuildPipelineTest { this.registerLibTester(new BuildInfoYamlLibTester( '', 'tests/jenkins/data/opensearch-2.2.0.yml', - 'tests/jenkins/data/buildInfo.yml', + 'tests/jenkins/data/job.yml', 'NOT_STARTED', 'START' ) diff --git a/tests/jenkins/data/BuildInfo.yml b/tests/jenkins/data/job.yml similarity index 100% rename from tests/jenkins/data/BuildInfo.yml rename to tests/jenkins/data/job.yml diff --git a/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile index deebdd4bae..14ac2ebbec 100644 --- a/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile +++ b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile @@ -15,28 +15,28 @@ pipeline { buildInfoYaml( componentName: "", inputManifest: "tests/jenkins/data/opensearch-2.2.0.yml", - outputFile: "tests/jenkins/data/buildInfo.yml", + outputFile: "tests/jenkins/data/job.yml", status: "NOT_STARTED", stage: "START" ) buildInfoYaml( componentName: "", - inputManifest: "tests/jenkins/data/buildInfo.yml", - outputFile: "tests/jenkins/data/buildInfo.yml", + inputManifest: "tests/jenkins/data/job.yml", + outputFile: "tests/jenkins/data/job.yml", status: "SUCCESS", stage: "x64_tar" ) buildInfoYaml( componentName: "", - inputManifest: "tests/jenkins/data/buildInfo.yml", - outputFile: "tests/jenkins/data/buildInfo.yml", + inputManifest: "tests/jenkins/data/job.yml", + outputFile: "tests/jenkins/data/job.yml", status: "6", stage: "integ_test_x64" ) buildInfoYaml( componentName: "", - inputManifest: "tests/jenkins/data/buildInfo.yml", - outputFile: "tests/jenkins/data/buildInfo.yml", + inputManifest: "tests/jenkins/data/job.yml", + outputFile: "tests/jenkins/data/job.yml", status: "SUCCESS", stage: "COMPLETE" ) diff --git a/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt index ac8444dd14..355c4cbe37 100644 --- a/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt +++ b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt @@ -3,7 +3,7 @@ BuildInfoYaml_Jenkinsfile.echo(Executing on agent [label:none]) BuildInfoYaml_Jenkinsfile.stage(Initialize the buildInfoYaml report, groovy.lang.Closure) BuildInfoYaml_Jenkinsfile.script(groovy.lang.Closure) - BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/opensearch-2.2.0.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=NOT_STARTED, stage=START}) + BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/opensearch-2.2.0.yml, outputFile=tests/jenkins/data/job.yml, status=NOT_STARTED, stage=START}) buildInfoYaml.unstash(job_yml) buildInfoYaml.echo(No job.yml exists in stashed. Please make sure inputManifest parameter is passed.) buildInfoYaml.readYaml({file=tests/jenkins/data/opensearch-2.2.0.yml}) @@ -12,13 +12,13 @@ buildInfoYaml.echo(Components parameter is null) buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) buildInfoYaml.echo(Initiate the job info yaml file.) - buildInfoYaml.writeYaml({file=job.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=IN_PROGRESS, number=123}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=2.2, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=2.x, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=2.2, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=2.2, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=2.2, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=2.2, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=2.2, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={}}, overwrite=true}) + buildInfoYaml.writeYaml({file=job.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=IN_PROGRESS, number=123}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=2.2, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=2.x, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=2.2, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=2.2, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=2.2, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=2.2, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=2.2, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={duration=1, startTimestamp=1}}, overwrite=true}) buildInfoYaml.sh(cat job.yml) buildInfoYaml.stash({includes=job.yml, name=job_yml}) - BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=SUCCESS, stage=x64_tar}) + BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/job.yml, outputFile=tests/jenkins/data/job.yml, status=SUCCESS, stage=x64_tar}) buildInfoYaml.unstash(job_yml) buildInfoYaml.echo(No job.yml exists in stashed. Please make sure inputManifest parameter is passed.) - buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) + buildInfoYaml.readYaml({file=tests/jenkins/data/job.yml}) buildInfoYaml.echo(The status is SUCCESS) buildInfoYaml.echo(Components is ) buildInfoYaml.echo(Components parameter is null) @@ -28,10 +28,10 @@ buildInfoYaml.writeYaml({file=job.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=SUCCESS, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=1, startTimestamp=1}}, overwrite=true}) buildInfoYaml.sh(cat job.yml) buildInfoYaml.stash({includes=job.yml, name=job_yml}) - BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=6, stage=integ_test_x64}) + BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/job.yml, outputFile=tests/jenkins/data/job.yml, status=6, stage=integ_test_x64}) buildInfoYaml.unstash(job_yml) buildInfoYaml.echo(No job.yml exists in stashed. Please make sure inputManifest parameter is passed.) - buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) + buildInfoYaml.readYaml({file=tests/jenkins/data/job.yml}) buildInfoYaml.echo(The status is 6) buildInfoYaml.echo(Components is ) buildInfoYaml.echo(Components parameter is null) @@ -41,10 +41,10 @@ buildInfoYaml.writeYaml({file=job.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=6, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=1, startTimestamp=1}}, overwrite=true}) buildInfoYaml.sh(cat job.yml) buildInfoYaml.stash({includes=job.yml, name=job_yml}) - BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=SUCCESS, stage=COMPLETE}) + BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/job.yml, outputFile=tests/jenkins/data/job.yml, status=SUCCESS, stage=COMPLETE}) buildInfoYaml.unstash(job_yml) buildInfoYaml.echo(No job.yml exists in stashed. Please make sure inputManifest parameter is passed.) - buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) + buildInfoYaml.readYaml({file=tests/jenkins/data/job.yml}) buildInfoYaml.echo(The status is SUCCESS) buildInfoYaml.echo(Components is ) buildInfoYaml.echo(Components parameter is null) @@ -103,6 +103,6 @@ buildInfoYaml.dir(dashboards-reports, groovy.lang.Closure) buildInfoYaml.checkout({$class=GitSCM, branches=[{name=1d3980ab2d93a89acd0a5716f575a222389b9e8d}], userRemoteConfigs=[{url=https://github.com/opensearch-project/dashboards-reports.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) - buildInfoYaml.writeYaml({file=job.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=154442, startTimestamp=1660345758679}}, overwrite=true}) + buildInfoYaml.writeYaml({file=job.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=1, startTimestamp=1}}, overwrite=true}) buildInfoYaml.sh(cat job.yml) buildInfoYaml.stash({includes=job.yml, name=job_yml}) diff --git a/vars/buildInfoYaml.groovy b/vars/buildInfoYaml.groovy index 4769793ad1..6ea1b5f325 100644 --- a/vars/buildInfoYaml.groovy +++ b/vars/buildInfoYaml.groovy @@ -37,7 +37,7 @@ def call(Map args = [:]) { if (componentsList.contains(component.name)) { // Convert ref from branch to commit dir(component.name) { - checkout([$class : 'GitSCM', branches: [[name: component.ref]], + checkout([$class: 'GitSCM', branches: [[name: component.ref]], userRemoteConfigs: [[url: component.repository]]]) def commitID = sh( script: "git rev-parse HEAD", @@ -53,9 +53,9 @@ def call(Map args = [:]) { echo("stage is $stageField") echo("status is $status") sourceyml.results.("$stageField".toString()) = status - sourceyml.results.duration = currentBuild.duration - sourceyml.results.startTimestamp = currentBuild.startTimeInMillis } + sourceyml.results.duration = currentBuild.duration + sourceyml.results.startTimestamp = currentBuild.startTimeInMillis writeYaml(file: outputyml, data: sourceyml, overwrite: true) sh ("cat $outputyml") stash includes: "job.yml", name: "job_yml" From 8aac7546f5556a9ceb053c7635da17cabff03d7d Mon Sep 17 00:00:00 2001 From: Zelin Hao Date: Tue, 23 Aug 2022 16:03:48 -0700 Subject: [PATCH 6/6] More changes Signed-off-by: Zelin Hao --- .../distribution-build.jenkinsfile | 9 ++- .../opensearch/distribution-build.jenkinsfile | 8 +-- tests/jenkins/TestBuildInfoYaml.groovy | 4 +- tests/jenkins/data/{job.yml => buildInfo.yml} | 4 -- tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile | 18 +++--- .../jobs/BuildInfoYaml_Jenkinsfile.txt | 56 +++++++++---------- vars/buildInfoYaml.groovy | 20 +++---- 7 files changed, 57 insertions(+), 62 deletions(-) rename tests/jenkins/data/{job.yml => buildInfo.yml} (98%) diff --git a/jenkins/opensearch-dashboards/distribution-build.jenkinsfile b/jenkins/opensearch-dashboards/distribution-build.jenkinsfile index 106b3bcb24..f6daefa585 100644 --- a/jenkins/opensearch-dashboards/distribution-build.jenkinsfile +++ b/jenkins/opensearch-dashboards/distribution-build.jenkinsfile @@ -79,7 +79,7 @@ pipeline { componentName: COMPONENT_NAME, inputManifest: "manifests/$INPUT_MANIFEST", status: "NOT_STARTED", - stage: "START" + stage: "INITIALIZE_STAGE" ) } } @@ -138,7 +138,6 @@ pipeline { stage: "integ_test_x64" ) - env.ARTIFACT_URL_X64_TAR_INTEG_TEST_RESULT = createTestResultsMessage( testType: "Integ Tests (x64, tar)", status: integTestResults.getResult(), @@ -558,10 +557,10 @@ pipeline { buildInfoYaml( componentName: COMPONENT_NAME, status: currentBuild.result, - stage: "COMPLETE" + stage: "FINALIZE_STAGE" ) - unstash "job_yml" - archiveArtifacts artifacts: 'job.yml' + unstash "buildInfo_yml" + archiveArtifacts artifacts: 'buildInfo.yml' postCleanup() } } diff --git a/jenkins/opensearch/distribution-build.jenkinsfile b/jenkins/opensearch/distribution-build.jenkinsfile index e1543f162f..13dcdf7fd0 100644 --- a/jenkins/opensearch/distribution-build.jenkinsfile +++ b/jenkins/opensearch/distribution-build.jenkinsfile @@ -79,7 +79,7 @@ pipeline { componentName: COMPONENT_NAME, inputManifest: "manifests/$INPUT_MANIFEST", status: "NOT_STARTED", - stage: "START" + stage: "INITIALIZE_STAGE" ) } } @@ -624,10 +624,10 @@ pipeline { buildInfoYaml( componentName: COMPONENT_NAME, status: currentBuild.result, - stage: "COMPLETE" + stage: "FINALIZE_STAGE" ) - unstash "job_yml" - archiveArtifacts artifacts: 'job.yml' + unstash "buildInfo_yml" + archiveArtifacts artifacts: 'buildInfo.yml' postCleanup() } } diff --git a/tests/jenkins/TestBuildInfoYaml.groovy b/tests/jenkins/TestBuildInfoYaml.groovy index c4c3c85bb2..c7f5329ee8 100644 --- a/tests/jenkins/TestBuildInfoYaml.groovy +++ b/tests/jenkins/TestBuildInfoYaml.groovy @@ -18,9 +18,9 @@ class TestBuildInfoYaml extends BuildPipelineTest { this.registerLibTester(new BuildInfoYamlLibTester( '', 'tests/jenkins/data/opensearch-2.2.0.yml', - 'tests/jenkins/data/job.yml', + 'tests/jenkins/data/buildInfo.yml', 'NOT_STARTED', - 'START' + 'INITIALIZE_STAGE' ) ) super.setUp() diff --git a/tests/jenkins/data/job.yml b/tests/jenkins/data/buildInfo.yml similarity index 98% rename from tests/jenkins/data/job.yml rename to tests/jenkins/data/buildInfo.yml index 17a509a42f..16ed7211f1 100644 --- a/tests/jenkins/data/job.yml +++ b/tests/jenkins/data/buildInfo.yml @@ -157,9 +157,5 @@ results: bwc_test_x64: NOT_STARTED integ_test_arm64: NOT_STARTED bwc_test_arm64: NOT_STARTED - x64_tar: NOT_STARTED - arm64_tar: NOT_STARTED - x64_rpm: NOT_STARTED - arm64_rpm: NOT_STARTED duration: 154442 startTimestamp: 1660345758679 diff --git a/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile index 14ac2ebbec..a75cca934f 100644 --- a/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile +++ b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile @@ -15,30 +15,30 @@ pipeline { buildInfoYaml( componentName: "", inputManifest: "tests/jenkins/data/opensearch-2.2.0.yml", - outputFile: "tests/jenkins/data/job.yml", + outputFile: "tests/jenkins/data/buildInfo.yml", status: "NOT_STARTED", - stage: "START" + stage: "INITIALIZE_STAGE" ) buildInfoYaml( componentName: "", - inputManifest: "tests/jenkins/data/job.yml", - outputFile: "tests/jenkins/data/job.yml", + inputManifest: "tests/jenkins/data/buildInfo.yml", + outputFile: "tests/jenkins/data/buildInfo.yml", status: "SUCCESS", stage: "x64_tar" ) buildInfoYaml( componentName: "", - inputManifest: "tests/jenkins/data/job.yml", - outputFile: "tests/jenkins/data/job.yml", + inputManifest: "tests/jenkins/data/buildInfo.yml", + outputFile: "tests/jenkins/data/buildInfo.yml", status: "6", stage: "integ_test_x64" ) buildInfoYaml( componentName: "", - inputManifest: "tests/jenkins/data/job.yml", - outputFile: "tests/jenkins/data/job.yml", + inputManifest: "tests/jenkins/data/buildInfo.yml", + outputFile: "tests/jenkins/data/buildInfo.yml", status: "SUCCESS", - stage: "COMPLETE" + stage: "FINALIZE_STAGE" ) } } diff --git a/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt index 355c4cbe37..5276261040 100644 --- a/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt +++ b/tests/jenkins/jobs/BuildInfoYaml_Jenkinsfile.txt @@ -3,48 +3,48 @@ BuildInfoYaml_Jenkinsfile.echo(Executing on agent [label:none]) BuildInfoYaml_Jenkinsfile.stage(Initialize the buildInfoYaml report, groovy.lang.Closure) BuildInfoYaml_Jenkinsfile.script(groovy.lang.Closure) - BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/opensearch-2.2.0.yml, outputFile=tests/jenkins/data/job.yml, status=NOT_STARTED, stage=START}) - buildInfoYaml.unstash(job_yml) - buildInfoYaml.echo(No job.yml exists in stashed. Please make sure inputManifest parameter is passed.) + BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/opensearch-2.2.0.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=NOT_STARTED, stage=INITIALIZE_STAGE}) + buildInfoYaml.unstash(buildInfo_yml) + buildInfoYaml.echo(No buildInfo.yml exists in stashed. Starting initialize the buildInfo yaml file.) buildInfoYaml.readYaml({file=tests/jenkins/data/opensearch-2.2.0.yml}) buildInfoYaml.echo(The status is NOT_STARTED) buildInfoYaml.echo(Components is ) buildInfoYaml.echo(Components parameter is null) buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) - buildInfoYaml.echo(Initiate the job info yaml file.) - buildInfoYaml.writeYaml({file=job.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=IN_PROGRESS, number=123}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=2.2, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=2.x, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=2.2, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=2.2, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=2.2, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=2.2, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=2.2, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={duration=1, startTimestamp=1}}, overwrite=true}) - buildInfoYaml.sh(cat job.yml) - buildInfoYaml.stash({includes=job.yml, name=job_yml}) - BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/job.yml, outputFile=tests/jenkins/data/job.yml, status=SUCCESS, stage=x64_tar}) - buildInfoYaml.unstash(job_yml) - buildInfoYaml.echo(No job.yml exists in stashed. Please make sure inputManifest parameter is passed.) - buildInfoYaml.readYaml({file=tests/jenkins/data/job.yml}) + buildInfoYaml.echo(Initiate the build info yaml file.) + buildInfoYaml.writeYaml({file=buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=IN_PROGRESS, number=123}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=2.2, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=2.x, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=2.2, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=2.2, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=2.2, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=2.2, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=2.2, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=2.2, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={startTimestamp=1}}, overwrite=true}) + buildInfoYaml.sh(cat buildInfo.yml) + buildInfoYaml.stash({includes=buildInfo.yml, name=buildInfo_yml}) + BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=SUCCESS, stage=x64_tar}) + buildInfoYaml.unstash(buildInfo_yml) + buildInfoYaml.echo(No buildInfo.yml exists in stashed. Starting initialize the buildInfo yaml file.) + buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) buildInfoYaml.echo(The status is SUCCESS) buildInfoYaml.echo(Components is ) buildInfoYaml.echo(Components parameter is null) buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) buildInfoYaml.echo(stage is x64_tar) buildInfoYaml.echo(status is SUCCESS) - buildInfoYaml.writeYaml({file=job.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=SUCCESS, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=1, startTimestamp=1}}, overwrite=true}) - buildInfoYaml.sh(cat job.yml) - buildInfoYaml.stash({includes=job.yml, name=job_yml}) - BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/job.yml, outputFile=tests/jenkins/data/job.yml, status=6, stage=integ_test_x64}) - buildInfoYaml.unstash(job_yml) - buildInfoYaml.echo(No job.yml exists in stashed. Please make sure inputManifest parameter is passed.) - buildInfoYaml.readYaml({file=tests/jenkins/data/job.yml}) + buildInfoYaml.writeYaml({file=buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, duration=154442, startTimestamp=1660345758679, x64_tar=SUCCESS}}, overwrite=true}) + buildInfoYaml.sh(cat buildInfo.yml) + buildInfoYaml.stash({includes=buildInfo.yml, name=buildInfo_yml}) + BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=6, stage=integ_test_x64}) + buildInfoYaml.unstash(buildInfo_yml) + buildInfoYaml.echo(No buildInfo.yml exists in stashed. Starting initialize the buildInfo yaml file.) + buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) buildInfoYaml.echo(The status is 6) buildInfoYaml.echo(Components is ) buildInfoYaml.echo(Components parameter is null) buildInfoYaml.echo([OpenSearch, common-utils, job-scheduler, ml-commons, performance-analyzer, security, geospatial, k-NN, cross-cluster-replication, notifications-core, notifications, anomaly-detection, asynchronous-search, alerting, index-management, sql, opensearch-observability, dashboards-reports]) buildInfoYaml.echo(stage is integ_test_x64) buildInfoYaml.echo(status is 6) - buildInfoYaml.writeYaml({file=job.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=6, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=1, startTimestamp=1}}, overwrite=true}) - buildInfoYaml.sh(cat job.yml) - buildInfoYaml.stash({includes=job.yml, name=job_yml}) - BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/job.yml, outputFile=tests/jenkins/data/job.yml, status=SUCCESS, stage=COMPLETE}) - buildInfoYaml.unstash(job_yml) - buildInfoYaml.echo(No job.yml exists in stashed. Please make sure inputManifest parameter is passed.) - buildInfoYaml.readYaml({file=tests/jenkins/data/job.yml}) + buildInfoYaml.writeYaml({file=buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=b1017fa3b9a1c781d4f34ecee411e0cdf930a515, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=ae064c5668f3d46ba8f47ad6e7ea23a14ede557b, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=a5013073ec8de9b7af6fa439c2f4d6fd9af8881d, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=a7d269500f8667fdd4cd4d582c7148a7e7fb557c, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=3a75d7d5a6302b3c9fd78fb7104f90689d407484, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=ff17b025d15793d600f4b31d6dd4bbde97030f39, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=a71475ab3b0de008ca352e290d99fb3b53f1a1c5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=53185a0f165ebe1f8c3e01fd80a867727ba3674f, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=719634b60056e48e35cccba1f1ed3a0a43bb90e5, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=01b4aa8886b4bb8faabf482bf9f4baaa441015fe, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=04f27418fe97110635b08dd986d77ce0ecc384ec, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=4f1f992c6bb134dab191042a87216f1616be8a27, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=b3d676f70b0df8df9cab0919a147ed395c568797, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=8eb5da6b0317506ee0160ddbbc53a14550cbcd5d, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=454122d3c73dcf8944800720e2116fd6540d3b26, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=4055decd159c2cff401b43006f6ccba73e6f67b6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=1d3980ab2d93a89acd0a5716f575a222389b9e8d, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=6, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, duration=154442, startTimestamp=1660345758679}}, overwrite=true}) + buildInfoYaml.sh(cat buildInfo.yml) + buildInfoYaml.stash({includes=buildInfo.yml, name=buildInfo_yml}) + BuildInfoYaml_Jenkinsfile.buildInfoYaml({componentName=, inputManifest=tests/jenkins/data/buildInfo.yml, outputFile=tests/jenkins/data/buildInfo.yml, status=SUCCESS, stage=FINALIZE_STAGE}) + buildInfoYaml.unstash(buildInfo_yml) + buildInfoYaml.echo(No buildInfo.yml exists in stashed. Starting initialize the buildInfo yaml file.) + buildInfoYaml.readYaml({file=tests/jenkins/data/buildInfo.yml}) buildInfoYaml.echo(The status is SUCCESS) buildInfoYaml.echo(Components is ) buildInfoYaml.echo(Components parameter is null) @@ -103,6 +103,6 @@ buildInfoYaml.dir(dashboards-reports, groovy.lang.Closure) buildInfoYaml.checkout({$class=GitSCM, branches=[{name=1d3980ab2d93a89acd0a5716f575a222389b9e8d}], userRemoteConfigs=[{url=https://github.com/opensearch-project/dashboards-reports.git}]}) buildInfoYaml.sh({script=git rev-parse HEAD, returnStdout=true}) - buildInfoYaml.writeYaml({file=job.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, x64_tar=NOT_STARTED, arm64_tar=NOT_STARTED, x64_rpm=NOT_STARTED, arm64_rpm=NOT_STARTED, duration=1, startTimestamp=1}}, overwrite=true}) - buildInfoYaml.sh(cat job.yml) - buildInfoYaml.stash({includes=job.yml, name=job_yml}) + buildInfoYaml.writeYaml({file=buildInfo.yml, data={schema-version=1.0, build={name=OpenSearch, version=2.2.0, status=SUCCESS, number=30}, ci={image={name=opensearchstaging/ci-runner:ci-runner-centos7-opensearch-build-v2, args=-e JAVA_HOME=/opt/java/openjdk-17}}, components=[{name=OpenSearch, repository=https://github.com/opensearch-project/OpenSearch.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, checks=[gradle:publish, gradle:properties:version]}, {name=common-utils, repository=https://github.com/opensearch-project/common-utils.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:publish, gradle:properties:version]}, {name=job-scheduler, repository=https://github.com/opensearch-project/job-scheduler.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=ml-commons, repository=https://github.com/opensearch-project/ml-commons.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-ml-plugin}]}, {name=performance-analyzer, repository=https://github.com/opensearch-project/performance-analyzer.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=security, repository=https://github.com/opensearch-project/security.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux]}, {name=geospatial, repository=https://github.com/opensearch-project/geospatial.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=k-NN, repository=https://github.com/opensearch-project/k-NN.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=cross-cluster-replication, repository=https://github.com/opensearch-project/cross-cluster-replication.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=notifications-core, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-notifications-core}]}, {name=notifications, repository=https://github.com/opensearch-project/notifications.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=notifications, checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=notifications}]}, {name=anomaly-detection, repository=https://github.com/opensearch-project/anomaly-detection.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=asynchronous-search, repository=https://github.com/opensearch-project/asynchronous-search.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=alerting, repository=https://github.com/opensearch-project/alerting.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=alerting}]}, {name=index-management, repository=https://github.com/opensearch-project/index-management.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version]}, {name=sql, repository=https://github.com/opensearch-project/sql.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], checks=[gradle:properties:version, {gradle:dependencies:opensearch.version=opensearch-sql-plugin}]}, {name=opensearch-observability, repository=https://github.com/opensearch-project/observability, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=opensearch-observability, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}, {name=dashboards-reports, repository=https://github.com/opensearch-project/dashboards-reports.git, ref=75eccfe03b4e58ede1a69eb6008196c44e7008c6, platforms=[linux], working_directory=reports-scheduler, checks=[gradle:properties:version, gradle:dependencies:opensearch.version]}], results={integ_test_x64=NOT_STARTED, bwc_test_x64=NOT_STARTED, integ_test_arm64=NOT_STARTED, bwc_test_arm64=NOT_STARTED, duration=1, startTimestamp=1660345758679}}, overwrite=true}) + buildInfoYaml.sh(cat buildInfo.yml) + buildInfoYaml.stash({includes=buildInfo.yml, name=buildInfo_yml}) diff --git a/vars/buildInfoYaml.groovy b/vars/buildInfoYaml.groovy index 6ea1b5f325..fc94026206 100644 --- a/vars/buildInfoYaml.groovy +++ b/vars/buildInfoYaml.groovy @@ -1,14 +1,14 @@ def call(Map args = [:]) { try { - unstash "job_yml" + unstash "buildInfo_yml" } catch(Exception ex) { - echo("No job.yml exists in stashed. Please make sure inputManifest parameter is passed.") + echo("No buildInfo.yml exists in stashed. Starting initialize the buildInfo yaml file.") } - def inputManifest = args.inputManifest ?: "job.yml" + def inputManifest = args.inputManifest ?: "buildInfo.yml" def sourceyml = readYaml(file: inputManifest) - def outputyml = args.outputyml ?: "job.yml" + def outputyml = args.outputyml ?: "buildInfo.yml" def components = args.componentName def componentsList = [] def status = args.status @@ -27,12 +27,13 @@ def call(Map args = [:]) { } echo (componentsList.toString()) - if (args.stage == "START") { - echo("Initiate the job info yaml file.") + if (args.stage == "INITIALIZE_STAGE") { + echo("Initiate the build info yaml file.") sourceyml.build.status = "IN_PROGRESS" sourceyml.build.number = "${BUILD_NUMBER}" sourceyml.results = [:] - } else if (args.stage == "COMPLETE") { + sourceyml.results.startTimestamp = currentBuild.startTimeInMillis + } else if (args.stage == "FINALIZE_STAGE") { sourceyml.components.each { component -> if (componentsList.contains(component.name)) { // Convert ref from branch to commit @@ -48,15 +49,14 @@ def call(Map args = [:]) { } } sourceyml.build.status = status + sourceyml.results.duration = currentBuild.duration } else { stageField = args.stage echo("stage is $stageField") echo("status is $status") sourceyml.results.("$stageField".toString()) = status } - sourceyml.results.duration = currentBuild.duration - sourceyml.results.startTimestamp = currentBuild.startTimeInMillis writeYaml(file: outputyml, data: sourceyml, overwrite: true) sh ("cat $outputyml") - stash includes: "job.yml", name: "job_yml" + stash includes: "buildInfo.yml", name: "buildInfo_yml" }