diff --git a/JenkinsJobs/Builds/FOLDER.groovy b/JenkinsJobs/Builds/FOLDER.groovy index 74f1e8c5788..a3deda47565 100644 --- a/JenkinsJobs/Builds/FOLDER.groovy +++ b/JenkinsJobs/Builds/FOLDER.groovy @@ -1,7 +1,48 @@ +def STREAMS = new groovy.json.JsonSlurper().parseText(readFileFromWorkspace('JenkinsJobs/JobDSL.json')).Streams + folder('Builds') { description('Eclipse periodic build jobs.') } +for (STREAM in STREAMS){ + + pipelineJob('Builds/I-build-' + STREAM){ + description('Daily Eclipse Integration builds.') + properties { + pipelineTriggers { + triggers { + cron { + spec('''TZ=America/Toronto +# format: Minute Hour Day Month Day of the week (0-7) + +# - - - Integration Eclipse SDK builds - - - +# 2025-03 Release Schedule +# Normal : 6 PM every day (1/6 - 2/9) +0 18 * * * + + +# Milestone/RC Schedule +# Post M1, no nightlies, I-builds only. (Be sure to "turn off" for tests and sign off days) +# 0 6 14-26 2 5-7,1-3 +# 0 18 14-26 2 5-7,1-3 +''') + } + } + } + } + definition { + cpsScm { + lightweight(true) + scm { + github('eclipse-platform/eclipse.platform.releng.aggregator', 'master') + } + scriptPath('JenkinsJobs/Builds/build.jenkinsfile') + } + } + } + +} + pipelineJob('Builds/Build-Docker-images'){ description('Build and publish custom Docker images') properties { diff --git a/JenkinsJobs/Builds/I_build.groovy b/JenkinsJobs/Builds/build.jenkinsfile similarity index 80% rename from JenkinsJobs/Builds/I_build.groovy rename to JenkinsJobs/Builds/build.jenkinsfile index a6239eae188..8377c4bf020 100644 --- a/JenkinsJobs/Builds/I_build.groovy +++ b/JenkinsJobs/Builds/build.jenkinsfile @@ -1,65 +1,43 @@ -def config = new groovy.json.JsonSlurper().parseText(readFileFromWorkspace('JenkinsJobs/JobDSL.json')) -def STREAMS = config.Streams -def TEST_CONFIGURATIONS = [ +def I_TEST_CONFIGURATIONS = [ [ os: 'linux' , ws: 'gtk' , arch: 'x86_64' , javaVersion: 21], [ os: 'linux' , ws: 'gtk' , arch: 'x86_64' , javaVersion: 23], [ os: 'macosx', ws: 'cocoa', arch: 'aarch64', javaVersion: 21], [ os: 'macosx', ws: 'cocoa', arch: 'x86_64' , javaVersion: 21], [ os: 'win32' , ws: 'win32', arch: 'x86_64' , javaVersion: 21], ] +def Y_TEST_CONFIGURATIONS = [ + [ os: 'linux' , ws: 'gtk' , arch: 'x86_64' , javaVersion: 21], + [ os: 'linux' , ws: 'gtk' , arch: 'x86_64' , javaVersion: 24], + [ os: 'macosx', ws: 'cocoa', arch: 'aarch64', javaVersion: 21], + [ os: 'macosx', ws: 'cocoa', arch: 'x86_64' , javaVersion: 21], +] +def BUILD = { + def matcher = "$JOB_BASE_NAME" =~ '(?[IY])-build-(?\\d).(?\\d+)' + if (matcher) { + def buildConfig = [ type: matcher.group('type'), testPrefix: "ep${matcher.group('major')}${matcher.group('minor')}${matcher.group('type')}-unit"] + switch(buildConfig.type) { + case 'I': return [*:buildConfig, + typeName: 'Integration' , branchLabel: 'master', + mailingList: 'platform-releng-dev@eclipse.org', testJobFolder:'AutomatedTests', testConfigurations: I_TEST_CONFIGURATIONS] + case 'Y': return [*:buildConfig, + typeName: 'Beta Java 24', branchLabel: 'java24', + mailingList: 'jdt-dev@eclipse.org' , testJobFolder:'YPBuilds' , testConfigurations: Y_TEST_CONFIGURATIONS] + } + } + throw new IllegalStateException("Unsupported job: $JOB_BASE_NAME" ) +}() -for (STREAM in STREAMS){ - def BRANCH = config.Branches[STREAM] - def MAJOR = STREAM.split('\\.')[0] - def MINOR = STREAM.split('\\.')[1] - - pipelineJob('Builds/I-build-' + STREAM){ - description('Daily Eclipse Integration builds.') - - properties { - pipelineTriggers { - triggers { - cron { - spec("""TZ=America/Toronto -# format: Minute Hour Day Month Day of the week (0-7) - -# - - - Integration Eclipse SDK builds - - - -# 2025-03 Release Schedule -# Normal : 6 PM every day (1/6 - 2/9) -0 18 * * * - - -# Milestone/RC Schedule -# Post M1, no nightlies, I-builds only. (Be sure to "turn off" for tests and sign off days) -# 0 6 14-26 2 5-7,1-3 -# 0 18 14-26 2 5-7,1-3 - """) - } - } - } - } - - logRotator { - numToKeep(25) - } - - definition { - cpsScm { - lightweight(true) - scm { - github('https://github.com/eclipse-platform/eclipse.platform.releng.aggregator/') - } - } +def testConfigurationsExpected = BUILD.testConfigurations.collect{c -> + "${BUILD.testPrefix}-${c.os}-${c.arch}-java${c.javaVersion}_${c.os}.${c.ws}.${c.arch}_${c.javaVersion}" + }.join(',') - cps { - sandbox() - script(''' pipeline { options { timeout(time: 360, unit: 'MINUTES') timestamps() buildDiscarder(logRotator(numToKeepStr:'25')) + skipDefaultCheckout() } agent { kubernetes { @@ -85,16 +63,14 @@ spec: maven 'apache-maven-latest' } environment { - BUILD_TYPE = 'I' - BUILD_TYPE_NAME = 'Integration' - PATCH_OR_BRANCH_LABEL = 'master' - + BUILD_TYPE = "${BUILD.type}" + BUILD_TYPE_NAME = "${BUILD.typeName}" + PATCH_OR_BRANCH_LABEL = "${BUILD.branchLabel}" + MAVEN_OPTS = "-Xmx6G" CJE_ROOT = "${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production" logDir = "$CJE_ROOT/buildlogs" - TEST_CONFIGURATIONS_EXPECTED = \'''' + TEST_CONFIGURATIONS.collect{c -> - 'ep' + MAJOR + MINOR + 'I-unit-' + c.os + '-' + c.arch + '-java' + c.javaVersion + '_' + c.os + '.' + c.ws + '.' + c.arch + '_' + c.javaVersion - }.join(',') + '''' + TEST_CONFIGURATIONS_EXPECTED = "${testConfigurationsExpected}" } stages { stage('Clean Workspace'){ @@ -106,21 +82,21 @@ spec: steps { sshagent(['github-bot-ssh']) { dir ('eclipse.platform.releng.aggregator') { - sh \'\'\' - git clone -b ''' + BRANCH + ''' git@github.com:eclipse-platform/eclipse.platform.releng.aggregator.git - \'\'\' + sh ''' + git clone -b master git@github.com:eclipse-platform/eclipse.platform.releng.aggregator.git + ''' } } - sh \'\'\' + sh ''' cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production chmod +x mbscripts/* mkdir -p $logDir - \'\'\' + ''' } } stage('Generate environment variables'){ steps { - sh \'\'\' + sh ''' cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts ./mb010_createEnvfiles.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb010_createEnvfiles.sh.log if [[ ${PIPESTATUS[0]} -ne 0 ]] @@ -128,7 +104,7 @@ spec: echo "Failed in Generate environment variables stage" exit 1 fi - \'\'\' + ''' } } stage('Load PGP keys'){ @@ -137,7 +113,7 @@ spec: KEYRING_PASSPHRASE = credentials('secret-subkeys-releng.acs-passphrase') } steps { - sh \'\'\' + sh ''' cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts ./mb011_loadPGPKeys.sh 2>&1 | tee $logDir/mb011_loadPGPKeys.sh.log if [[ ${PIPESTATUS[0]} -ne 0 ]] @@ -145,7 +121,7 @@ spec: echo "Failed in Load PGP keys" exit 1 fi - \'\'\' + ''' } } stage('Export environment variables stage 1'){ @@ -162,7 +138,7 @@ spec: steps { sshagent(['projects-storage.eclipse.org-bot-ssh']) { withAnt(installation: 'apache-ant-latest') { - sh \'\'\' + sh ''' cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts ./mb020_createBaseBuilder.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb020_createBaseBuilder.sh.log if [[ ${PIPESTATUS[0]} -ne 0 ]] @@ -170,7 +146,7 @@ spec: echo "Failed in Create Base builder stage" exit 1 fi - \'\'\' + ''' } } } @@ -178,7 +154,7 @@ spec: stage('Download reference repo for repo reports'){ steps { sshagent(['projects-storage.eclipse.org-bot-ssh']) { - sh \'\'\' + sh ''' cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts ./mb030_downloadBuildToCompare.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb030_downloadBuildToCompare.sh.log if [[ ${PIPESTATUS[0]} -ne 0 ]] @@ -186,14 +162,14 @@ spec: echo "Failed in Download reference repo for repo reports stage" exit 1 fi - \'\'\' + ''' } } } stage('Clone Repositories'){ steps { sshagent(['git.eclipse.org-bot-ssh', 'github-bot-ssh']) { - sh \'\'\' + sh ''' git config --global user.email "eclipse-releng-bot@eclipse.org" git config --global user.name "Eclipse Releng Bot" cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts @@ -203,7 +179,7 @@ spec: echo "Failed in Clone Repositories stage" exit 1 fi - \'\'\' + ''' } } } @@ -213,7 +189,7 @@ spec: } steps { sshagent (['git.eclipse.org-bot-ssh', 'github-bot-ssh', 'projects-storage.eclipse.org-bot-ssh']) { - sh \'\'\' + sh ''' cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts bash -x ./mb110_tagBuildInputs.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb110_tagBuildInputs.sh.log if [[ ${PIPESTATUS[0]} -ne 0 ]] @@ -221,13 +197,13 @@ spec: echo "Failed in Tag Build Inputs stage" exit 1 fi - \'\'\' + ''' } script { if (env.ABORT_IF_NO_CHANGES && fileExists("${WORKSPACE}/noChanges")) { - emailext subject: "${env.BUILD_VERSION} I-Build: ${env.BUILD_IID.trim()} - BUILD SKIPPED", + emailext subject: "${env.BUILD_VERSION} ${env.BUILD_TYPE}-Build: ${env.BUILD_IID.trim()} - BUILD SKIPPED", body: "The scheduled build was skipped because no changes have been made since the last successful build.
For details see ${BUILD_URL}console
", - to: 'platform-releng-dev@eclipse.org', + to: "${BUILD.mailingList}", from: 'genie.releng@eclipse.org' currentBuild.result = 'ABORTED' error('Abort scheduled build due to no changes') @@ -241,7 +217,7 @@ spec: MAVEN_GPG_PASSPHRASE = credentials('secret-subkeys-releng.acs-passphrase') } steps { - sh \'\'\' + sh ''' cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts unset JAVA_TOOL_OPTIONS unset _JAVA_OPTIONS @@ -251,7 +227,7 @@ spec: echo "Failed in Aggregator maven build stage" exit 1 fi - \'\'\' + ''' } } stage('Gather Eclipse Parts'){ @@ -261,7 +237,7 @@ spec: } steps { withAnt(installation: 'apache-ant-latest') { - sh \'\'\' + sh ''' cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts bash -x ./mb300_gatherEclipseParts.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb300_gatherEclipseParts.sh.log if [[ ${PIPESTATUS[0]} -ne 0 ]] @@ -269,7 +245,7 @@ spec: echo "Failed in Gather Eclipse Parts stage" exit 1 fi - \'\'\' + ''' } } } @@ -280,7 +256,7 @@ spec: } steps { withAnt(installation: 'apache-ant-latest') { - sh \'\'\' + sh ''' cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts ./mb310_gatherEquinoxParts.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb310_gatherEquinoxParts.sh.log if [[ ${PIPESTATUS[0]} -ne 0 ]] @@ -288,13 +264,13 @@ spec: echo "Failed in Gather Equinox Parts stage" exit 1 fi - \'\'\' + ''' } } } stage('Generate Repo reports'){ steps { - sh \'\'\' + sh ''' cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts unset JAVA_TOOL_OPTIONS unset _JAVA_OPTIONS @@ -304,12 +280,12 @@ spec: echo "Failed in Generate Repo reports stage" exit 1 fi - \'\'\' + ''' } } stage('Generate API tools reports'){ steps { - sh \'\'\' + sh ''' cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts unset JAVA_TOOL_OPTIONS unset _JAVA_OPTIONS @@ -319,7 +295,7 @@ spec: echo "Failed in Generate API tools reports stage" exit 1 fi - \'\'\' + ''' } } stage('Export environment variables stage 2'){ @@ -338,7 +314,7 @@ spec: } stage('Archive artifacts'){ steps { - sh \'\'\' + sh ''' cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production source $CJE_ROOT/buildproperties.shsource cp -r $logDir/* $CJE_ROOT/$DROP_DIR/$BUILD_ID/buildlogs @@ -349,17 +325,17 @@ spec: cp $CJE_ROOT/buildproperties.properties $CJE_ROOT/$DROP_DIR/$BUILD_ID cp $CJE_ROOT/buildproperties.shsource $CJE_ROOT/$DROP_DIR/$BUILD_ID cp $CJE_ROOT/$DROP_DIR/$BUILD_ID/buildproperties.* $CJE_ROOT/$EQUINOX_DROP_DIR/$BUILD_ID - \'\'\' + ''' archiveArtifacts '**/siteDir/**' } } stage('Promote Eclipse platform'){ steps { sshagent(['projects-storage.eclipse.org-bot-ssh']) { - sh \'\'\' + sh ''' cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts ./mb600_promoteEclipse.sh $CJE_ROOT/buildproperties.shsource - \'\'\' + ''' } build job: 'eclipse.releng.updateIndex', wait: false } @@ -367,36 +343,41 @@ spec: stage('Promote Equinox'){ steps { sshagent(['projects-storage.eclipse.org-bot-ssh']) { - sh \'\'\' + sh ''' cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts ./mb610_promoteEquinox.sh $CJE_ROOT/buildproperties.shsource - \'\'\' + ''' } } } stage('Promote Update Site'){ steps { sshagent(['projects-storage.eclipse.org-bot-ssh']) { - sh \'\'\' + sh ''' cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts ./mb620_promoteUpdateSite.sh $CJE_ROOT/buildproperties.shsource - \'\'\' + ''' } } } - stage('Trigger tests'){ - steps { -''' + TEST_CONFIGURATIONS.collect{ c -> -" build job: 'AutomatedTests/ep" + MAJOR + MINOR + 'I-unit-' + c.os + '-' + c.arch + '-' + 'java'+ c.javaVersion + '''', parameters: [string(name: 'buildId', value: "${env.BUILD_IID.trim()}")], wait: false''' -}.join('\n') + ''' + stage('Trigger tests'){ + steps { + script { + for (c in BUILD.testConfigurations) { + build job: "${BUILD.testJobFolder}/${BUILD.testPrefix}-${c.os}-${c.arch}-java${c.javaVersion}", parameters: [string(name: 'buildId', value: "${env.BUILD_IID.trim()}")], wait: false + } + } build job: 'SmokeTests/Start-smoke-tests', parameters: [string(name: 'buildId', value: "${env.BUILD_IID.trim()}")], wait: false } } stage('Trigger publication to Maven snapshots repo') { when { + allOf { + environment name: 'BUILD_TYPE', value: 'I' expression { env.COMPARATOR_ERRORS_SUBJECT.trim().isEmpty() } // On comparator-erros, skip the deployment of snapshot version to the 'eclipse-snapshots' maven repository to prevent that ECJ snapshot // from being used in verification builds. Similar to how the p2-repository is not added to the I-build composite in that case. + } } steps { build job: 'CBIaggregator', parameters: [string(name: 'snapshotOrRelease', value: '-snapshot')], wait: false @@ -406,22 +387,16 @@ spec: post { failure { emailext body: "Please go to ${BUILD_URL}console and check the build failure.

", - subject: "${env.BUILD_VERSION} I-Build: ${env.BUILD_IID.trim()} - BUILD FAILED", - to: "platform-releng-dev@eclipse.org", + subject: "${env.BUILD_VERSION} ${env.BUILD_TYPE}-Build: ${env.BUILD_IID.trim()} - BUILD FAILED", + to: "${BUILD.mailingList}", from:"genie.releng@eclipse.org" archive '${CJE_ROOT}/siteDir/eclipse/downloads/drops4/${env.BUILD_IID.trim()}/gitLog.html, $CJE_ROOT/gitCache/eclipse.platform.releng.aggregator' } success { - emailext body: "Eclipse downloads:
https://download.eclipse.org/eclipse/downloads/drops4/${env.BUILD_IID.trim()}

Build logs and/or test results (eventually):
https://download.eclipse.org/eclipse/downloads/drops4/${env.BUILD_IID.trim()}/testResults.php

${env.POM_UPDATES_BODY.trim()}${env.COMPARATOR_ERRORS_BODY.trim()}Software site repository:
https://download.eclipse.org/eclipse/updates/${env.RELEASE_VER.trim()}-I-builds

Specific (simple) site repository:
https://download.eclipse.org/eclipse/updates/${env.RELEASE_VER.trim()}-I-builds/${env.BUILD_IID.trim()}

Equinox downloads:
https://download.eclipse.org/equinox/drops/${env.BUILD_IID.trim()}

", - subject: "${env.BUILD_VERSION} I-Build: ${env.BUILD_IID.trim()} ${env.POM_UPDATES_SUBJECT.trim()} ${env.COMPARATOR_ERRORS_SUBJECT.trim()}", - to: "platform-releng-dev@eclipse.org", + emailext body: "Eclipse downloads:
https://download.eclipse.org/eclipse/downloads/drops4/${env.BUILD_IID.trim()}

Build logs and/or test results (eventually):
https://download.eclipse.org/eclipse/downloads/drops4/${env.BUILD_IID.trim()}/testResults.php

${env.POM_UPDATES_BODY.trim()}${env.COMPARATOR_ERRORS_BODY.trim()}Software site repository:
https://download.eclipse.org/eclipse/updates/${env.RELEASE_VER.trim()}-${env.BUILD_TYPE}-builds

Specific (simple) site repository:
https://download.eclipse.org/eclipse/updates/${env.RELEASE_VER.trim()}-${env.BUILD_TYPE}-builds/${env.BUILD_IID.trim()}

Equinox downloads:
https://download.eclipse.org/equinox/drops/${env.BUILD_IID.trim()}

", + subject: "${env.BUILD_VERSION} ${env.BUILD_TYPE}-Build: ${env.BUILD_IID.trim()} ${env.POM_UPDATES_SUBJECT.trim()} ${env.COMPARATOR_ERRORS_SUBJECT.trim()}", + to: "${BUILD.mailingList}", from:"genie.releng@eclipse.org" } } } - - ''') - } - } - } -} diff --git a/JenkinsJobs/JobDSL.json b/JenkinsJobs/JobDSL.json index 94202a8f0bc..e9957183e3d 100644 --- a/JenkinsJobs/JobDSL.json +++ b/JenkinsJobs/JobDSL.json @@ -2,7 +2,4 @@ "Streams": [ "4.35" ], - "Branches": { - "4.35": "master" - } } diff --git a/JenkinsJobs/YBuilds/FOLDER.groovy b/JenkinsJobs/YBuilds/FOLDER.groovy index f29573d53fa..4c8dc6e48d7 100644 --- a/JenkinsJobs/YBuilds/FOLDER.groovy +++ b/JenkinsJobs/YBuilds/FOLDER.groovy @@ -1,4 +1,42 @@ +def STREAMS = new groovy.json.JsonSlurper().parseText(readFileFromWorkspace('JenkinsJobs/JobDSL.json')).Streams + folder('YPBuilds') { displayName('Y and P Builds') description('Builds and tests for the beta java builds.') } + +for (STREAM in STREAMS){ + + pipelineJob('YPBuilds/Y-build-' + STREAM){ + description('Daily Maintenance Builds.') + properties { + pipelineTriggers { + triggers { + cron { + spec('''TZ=America/Toronto +# format: Minute Hour Day Month Day of the week (0-7) + +#Daily Y-build +0 10 * * * +#milestone week +#0 6 * * 2 +#0 6 * * 4 +# +#0 2 21 7 4 +''') + } + } + } + } + definition { + cpsScm { + lightweight(true) + scm { + github('eclipse-platform/eclipse.platform.releng.aggregator', 'master') + } + scriptPath('JenkinsJobs/Builds/build.jenkinsfile') + } + } + } + +} diff --git a/JenkinsJobs/YBuilds/Y_build.groovy b/JenkinsJobs/YBuilds/Y_build.groovy deleted file mode 100644 index 6e6893ffddb..00000000000 --- a/JenkinsJobs/YBuilds/Y_build.groovy +++ /dev/null @@ -1,413 +0,0 @@ -def config = new groovy.json.JsonSlurper().parseText(readFileFromWorkspace('JenkinsJobs/JobDSL.json')) -def STREAMS = config.Streams - -def TEST_CONFIGURATIONS = [ - [ os: 'linux' , ws: 'gtk' , arch: 'x86_64' , javaVersion: 21], - [ os: 'linux' , ws: 'gtk' , arch: 'x86_64' , javaVersion: 24], - [ os: 'macosx', ws: 'cocoa', arch: 'aarch64', javaVersion: 21], - [ os: 'macosx', ws: 'cocoa', arch: 'x86_64' , javaVersion: 21], -] - -for (STREAM in STREAMS){ - def BRANCH = config.Branches[STREAM] - def MAJOR = STREAM.split('\\.')[0] - def MINOR = STREAM.split('\\.')[1] - - pipelineJob('YPBuilds/Y-build-' + STREAM){ - description('Daily Maintenance Builds.') - - properties { - pipelineTriggers { - triggers { - cron { - spec("""TZ=America/Toronto -# format: Minute Hour Day Month Day of the week (0-7) - -#Daily Y-build -0 10 * * * -#milestone week -#0 6 * * 2 -#0 6 * * 4 -# -#0 2 21 7 4 - """) - } - } - } - } - - logRotator { - numToKeep(25) - } - - definition { - cpsScm { - lightweight(true) - scm { - github('https://github.com/eclipse-platform/eclipse.platform.releng.aggregator/', 'master') - } - } - - cps { - sandbox() - script(''' -pipeline { - options { - timeout(time: 360, unit: 'MINUTES') - timestamps() - buildDiscarder(logRotator(numToKeepStr:'25')) - } - agent { - kubernetes { - inheritFrom 'ubuntu-2404' - yaml """ -apiVersion: v1 -kind: Pod -spec: - containers: - - name: "jnlp" - resources: - limits: - memory: "8192Mi" - cpu: "4000m" - requests: - memory: "6144Mi" - cpu: "2000m" -""" - } - } - tools { - jdk 'temurin-jdk21-latest' - maven 'apache-maven-latest' - } - environment { - BUILD_TYPE = 'Y' - BUILD_TYPE_NAME = 'Beta Java 24' - PATCH_OR_BRANCH_LABEL = 'java24' - - MAVEN_OPTS = "-Xmx6G" - CJE_ROOT = "${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production" - logDir = "$CJE_ROOT/buildlogs" - TEST_CONFIGURATIONS_EXPECTED = \'''' + TEST_CONFIGURATIONS.collect{c -> - 'ep' + MAJOR + MINOR + 'Y-unit-' + c.os + '-' + c.arch + '-java' + c.javaVersion + '_' + c.os + '.' + c.ws + '.' + c.arch + '_' + c.javaVersion - }.join(',') + '''' - } - - stages { - stage('Clean Workspace'){ - steps { - cleanWs() - } - } - stage('Setup intial configuration'){ - steps { - sshagent(['github-bot-ssh']) { - dir ('eclipse.platform.releng.aggregator') { - sh \'\'\' - git clone -b master git@github.com:eclipse-platform/eclipse.platform.releng.aggregator.git - \'\'\' - } - } - sh \'\'\' - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production - chmod +x mbscripts/* - mkdir -p $logDir - \'\'\' - } - } - stage('Generate environment variables'){ - steps { - sh \'\'\' - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts - ./mb010_createEnvfiles.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb010_createEnvfiles.sh.log - if [[ ${PIPESTATUS[0]} -ne 0 ]] - then - echo "Failed in Generate environment variables stage" - exit 1 - fi - \'\'\' - } - } - stage('Load PGP keys'){ - environment { - KEYRING = credentials('secret-subkeys-releng.asc') - KEYRING_PASSPHRASE = credentials('secret-subkeys-releng.acs-passphrase') - } - steps { - sh \'\'\' - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts - ./mb011_loadPGPKeys.sh 2>&1 | tee $logDir/mb011_loadPGPKeys.sh.log - if [[ ${PIPESTATUS[0]} -ne 0 ]] - then - echo "Failed in Load PGP keys" - exit 1 - fi - \'\'\' - } - } - stage('Export environment variables stage 1'){ - steps { - script { - env.BUILD_IID = sh(script:'echo $(source $CJE_ROOT/buildproperties.shsource;echo $BUILD_TYPE$TIMESTAMP)', returnStdout: true) - env.BUILD_VERSION = sh(script:'echo $(source $CJE_ROOT/buildproperties.shsource;echo $RELEASE_VER)', returnStdout: true) - env.STREAM = sh(script:'echo $(source $CJE_ROOT/buildproperties.shsource;echo $STREAM)', returnStdout: true) - env.RELEASE_VER = sh(script:'echo $(source $CJE_ROOT/buildproperties.shsource;echo $RELEASE_VER)', returnStdout: true) - } - } - } - stage('Create Base builder'){ - steps { - sshagent(['projects-storage.eclipse.org-bot-ssh']) { - withAnt(installation: 'apache-ant-latest') { - sh \'\'\' - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts - ./mb020_createBaseBuilder.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb020_createBaseBuilder.sh.log - if [[ ${PIPESTATUS[0]} -ne 0 ]] - then - echo "Failed in Create Base builder stage" - exit 1 - fi - \'\'\' - } - } - } - } - stage('Download reference repo for repo reports'){ - steps { - sshagent(['projects-storage.eclipse.org-bot-ssh']) { - sh \'\'\' - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts - ./mb030_downloadBuildToCompare.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb030_downloadBuildToCompare.sh.log - if [[ ${PIPESTATUS[0]} -ne 0 ]] - then - echo "Failed in Download reference repo for repo reports stage" - exit 1 - fi - \'\'\' - } - } - } - stage('Clone Repositories'){ - steps { - sshagent(['git.eclipse.org-bot-ssh', 'github-bot-ssh']) { - sh \'\'\' - git config --global user.email "eclipse-releng-bot@eclipse.org" - git config --global user.name "Eclipse Releng Bot" - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts - ./mb100_cloneRepos.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb100_cloneRepos.sh.log - if [[ ${PIPESTATUS[0]} -ne 0 ]] - then - echo "Failed in Clone Repositories stage" - exit 1 - fi - \'\'\' - } - } - } - stage('Tag Build Inputs'){ - environment { - ABORT_IF_NO_CHANGES = "${!currentBuild.getBuildCauses('hudson.triggers.TimerTrigger$TimerTriggerCause').isEmpty()}" // true, if triggered by timer - } - steps { - sshagent (['git.eclipse.org-bot-ssh', 'github-bot-ssh', 'projects-storage.eclipse.org-bot-ssh']) { - sh \'\'\' - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts - bash -x ./mb110_tagBuildInputs.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb110_tagBuildInputs.sh.log - if [[ ${PIPESTATUS[0]} -ne 0 ]] - then - echo "Failed in Tag Build Inputs stage" - exit 1 - fi - \'\'\' - } - script { - if (env.ABORT_IF_NO_CHANGES && fileExists("${WORKSPACE}/noChanges")) { - emailext subject: "${env.BUILD_VERSION} I-Build: ${env.BUILD_IID.trim()} - BUILD SKIPPED", - body: "The scheduled build was skipped because no changes have been made since the last successful build.
For details see ${BUILD_URL}console
", - to: 'jdt-dev@eclipse.org', - from: 'genie.releng@eclipse.org' - currentBuild.result = 'ABORTED' - error('Abort scheduled build due to no changes') - } - } - } - } - stage('Aggregator maven build'){ - environment { - KEYRING = credentials('secret-subkeys-releng.asc') - MAVEN_GPG_PASSPHRASE = credentials('secret-subkeys-releng.acs-passphrase') - } - steps { - sh \'\'\' - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts - unset JAVA_TOOL_OPTIONS - unset _JAVA_OPTIONS - ./mb220_buildSdkPatch.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb220_buildSdkPatch.sh.log - if [[ ${PIPESTATUS[0]} -ne 0 ]] - then - echo "Failed in Aggregator maven build stage" - exit 1 - fi - \'\'\' - } - } - stage('Gather Eclipse Parts'){ - environment { - KEYRING = credentials('secret-subkeys-releng.asc') - KEYRING_PASSPHRASE = credentials('secret-subkeys-releng.acs-passphrase') - } - steps { - withAnt(installation: 'apache-ant-latest') { - sh \'\'\' - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts - bash -x ./mb300_gatherEclipseParts.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb300_gatherEclipseParts.sh.log - if [[ ${PIPESTATUS[0]} -ne 0 ]] - then - echo "Failed in Gather Eclipse Parts stage" - exit 1 - fi - \'\'\' - } - } - } - stage('Gather Equinox Parts'){ - environment { - KEYRING = credentials('secret-subkeys-releng.asc') - KEYRING_PASSPHRASE = credentials('secret-subkeys-releng.acs-passphrase') - } - steps { - withAnt(installation: 'apache-ant-latest') { - sh \'\'\' - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts - ./mb310_gatherEquinoxParts.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb310_gatherEquinoxParts.sh.log - if [[ ${PIPESTATUS[0]} -ne 0 ]] - then - echo "Failed in Gather Equinox Parts stage" - exit 1 - fi - \'\'\' - } - } - } - stage('Generate Repo reports'){ - steps { - sh \'\'\' - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts - unset JAVA_TOOL_OPTIONS - unset _JAVA_OPTIONS - ./mb500_createRepoReports.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb500_createRepoReports.sh.log - if [[ ${PIPESTATUS[0]} -ne 0 ]] - then - echo "Failed in Generate Repo reports stage" - exit 1 - fi - \'\'\' - } - } - stage('Generate API tools reports'){ - steps { - sh \'\'\' - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts - unset JAVA_TOOL_OPTIONS - unset _JAVA_OPTIONS - ./mb510_createApiToolsReports.sh $CJE_ROOT/buildproperties.shsource 2>&1 | tee $logDir/mb510_createApiToolsReports.sh.log - if [[ ${PIPESTATUS[0]} -ne 0 ]] - then - echo "Failed in Generate API tools reports stage" - exit 1 - fi - \'\'\' - } - } - stage('Export environment variables stage 2'){ - steps { - script { - env.BUILD_IID = sh(script:'echo $(source $CJE_ROOT/buildproperties.shsource;echo $BUILD_TYPE$TIMESTAMP)', returnStdout: true) - env.BUILD_VERSION = sh(script:'echo $(source $CJE_ROOT/buildproperties.shsource;echo $RELEASE_VER)', returnStdout: true) - env.STREAM = sh(script:'echo $(source $CJE_ROOT/buildproperties.shsource;echo $STREAM)', returnStdout: true) - env.COMPARATOR_ERRORS_SUBJECT = sh(script:'echo $(source $CJE_ROOT/buildproperties.shsource;echo $COMPARATOR_ERRORS_SUBJECT)', returnStdout: true) - env.COMPARATOR_ERRORS_BODY = sh(script:'echo $(source $CJE_ROOT/buildproperties.shsource;echo $COMPARATOR_ERRORS_BODY)', returnStdout: true) - env.POM_UPDATES_SUBJECT = sh(script:'echo $(source $CJE_ROOT/buildproperties.shsource;echo $POM_UPDATES_SUBJECT)', returnStdout: true) - env.POM_UPDATES_BODY = sh(script:'echo $(source $CJE_ROOT/buildproperties.shsource;echo $POM_UPDATES_BODY)', returnStdout: true) - env.RELEASE_VER = sh(script:'echo $(source $CJE_ROOT/buildproperties.shsource;echo $RELEASE_VER)', returnStdout: true) - } - } - } - stage('Archive artifacts'){ - steps { - sh \'\'\' - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production - source $CJE_ROOT/buildproperties.shsource - cp -r $logDir/* $CJE_ROOT/$DROP_DIR/$BUILD_ID/buildlogs - rm -rf $logDir - rm -rf $CJE_ROOT/$DROP_DIR/$BUILD_ID/apitoolingreference - cp $CJE_ROOT/buildproperties.txt $CJE_ROOT/$DROP_DIR/$BUILD_ID - cp $CJE_ROOT/buildproperties.php $CJE_ROOT/$DROP_DIR/$BUILD_ID - cp $CJE_ROOT/buildproperties.properties $CJE_ROOT/$DROP_DIR/$BUILD_ID - cp $CJE_ROOT/buildproperties.shsource $CJE_ROOT/$DROP_DIR/$BUILD_ID - cp $CJE_ROOT/$DROP_DIR/$BUILD_ID/buildproperties.* $CJE_ROOT/$EQUINOX_DROP_DIR/$BUILD_ID - \'\'\' - archiveArtifacts '**/siteDir/**' - } - } - stage('Promote Eclipse platform'){ - steps { - sshagent(['projects-storage.eclipse.org-bot-ssh']) { - sh \'\'\' - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts - ./mb600_promoteEclipse.sh $CJE_ROOT/buildproperties.shsource - \'\'\' - } - build job: 'eclipse.releng.updateIndex', wait: false - } - } - stage('Promote Equinox'){ - steps { - sshagent(['projects-storage.eclipse.org-bot-ssh']) { - sh \'\'\' - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts - ./mb610_promoteEquinox.sh $CJE_ROOT/buildproperties.shsource - \'\'\' - } - } - } - stage('Promote Update Site'){ - steps { - sshagent(['projects-storage.eclipse.org-bot-ssh']) { - sh \'\'\' - cd ${WORKSPACE}/eclipse.platform.releng.aggregator/eclipse.platform.releng.aggregator/cje-production/mbscripts - ./mb620_promoteUpdateSite.sh $CJE_ROOT/buildproperties.shsource - \'\'\' - } - } - } - stage('Trigger tests'){ - steps { -''' + TEST_CONFIGURATIONS.collect{ c -> -" build job: 'YPBuilds/ep" + MAJOR + MINOR + 'Y-unit-' + c.os + '-' + c.arch + '-' + 'java'+ c.javaVersion + '''', parameters: [string(name: 'buildId', value: "${env.BUILD_IID.trim()}")], wait: false''' -}.join('\n') + ''' - build job: 'SmokeTests/Start-smoke-tests', parameters: [string(name: 'buildId', value: "${env.BUILD_IID.trim()}")], wait: false - } - } - } - post { - failure { - emailext body: "Please go to ${BUILD_URL}console and check the build failure.

", - subject: "${env.BUILD_VERSION} Y-Build: ${env.BUILD_IID.trim()} - BUILD FAILED", - to: 'jdt-dev@eclipse.org', - from:"genie.releng@eclipse.org" - } - success { - emailext body: "Eclipse downloads:
https://download.eclipse.org/eclipse/downloads/drops4/${env.BUILD_IID.trim()}

Build logs and/or test results (eventually):
https://download.eclipse.org/eclipse/downloads/drops4/${env.BUILD_IID.trim()}/testResults.php

${env.POM_UPDATES_BODY.trim()}${env.COMPARATOR_ERRORS_BODY.trim()}Software site repository:
https://download.eclipse.org/eclipse/updates/${env.RELEASE_VER.trim()}-Y-builds

Specific (simple) site repository:
https://download.eclipse.org/eclipse/updates/${env.RELEASE_VER.trim()}-Y-builds/${env.BUILD_IID.trim()}

Equinox downloads:
https://download.eclipse.org/equinox/drops/${env.BUILD_IID.trim()}

", - subject: "${env.BUILD_VERSION} Y-Build: ${env.BUILD_IID.trim()} ${env.POM_UPDATES_SUBJECT.trim()} ${env.COMPARATOR_ERRORS_SUBJECT.trim()}", - to: 'jdt-dev@eclipse.org', - from:"genie.releng@eclipse.org" - } - } -} - - ''') - } - } - } -} diff --git a/RELEASE.md b/RELEASE.md index 3fb11bc1436..6c8343ad98e 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -5,7 +5,7 @@ ## Milestone and RC Releases ### Friday before release week: - * Update [I-builds](JenkinsJobs/Builds/I_build.groovy) to build on the milestone schedule (Twice daily at 06:00 EST and 18:00 EST except Thursday). + * Update [I-builds job definition](JenkinsJobs/Builds/FOLDER.groovy) to build on the milestone schedule (Twice daily at 06:00 EST and 18:00 EST except Thursday). * Create or update prerequisite issues for tracking ECF, EMF and Orbit * Send reminder email for upcoming RC week to platform-releng-dev@eclipse.org, platform-dev@eclipse.org, eclipse-dev@eclipse.org and equinox-dev@eclipse.org * [Example from 4.30 RC1](https://www.eclipse.org/lists/platform-dev/msg03924.html) but the usual schedule: @@ -184,9 +184,8 @@ The release is scheduled for 10AM EST. Typically the jobs are scheduled beforeha #### **Update Jenkins for the next Release:** - Edit the [JobDSL.json](JenkinsJobs/JobDSL.json) * Add the next release version to the `Streams` key item. - * In the `branches` item update the current release to map to the maintenance branch and add a new key:value pair mapping the next release to master. - Run the [Create Jobs](https://ci.eclipse.org/releng/job/Create%20Jobs/) job in Jenkins. - This should move the current I-builds to run on the maintenance branch and create new I-builds for the next release. + This should create new I-builds for the next release. Performance and Unit tests should also be generated for the new release automatically. #### **Create new Stream Repos:**