From 63e20404a2f59dc6d8db75dfa4eeb14e9f50b681 Mon Sep 17 00:00:00 2001 From: Brian Clozel Date: Wed, 12 Apr 2023 15:15:29 +0200 Subject: [PATCH] Configure JDK 21 CI build This commit replaces the JDK 20 compatibility build with a JDK 21 (early access) variant. See gh-30339 --- ci/images/ci-image/Dockerfile | 2 +- ci/images/get-jdk-url.sh | 3 +++ ci/pipeline.yml | 16 ++++++++-------- ci/scripts/check-project.sh | 2 +- 4 files changed, 13 insertions(+), 10 deletions(-) diff --git a/ci/images/ci-image/Dockerfile b/ci/images/ci-image/Dockerfile index 26774ad3f8..26b56cbd99 100644 --- a/ci/images/ci-image/Dockerfile +++ b/ci/images/ci-image/Dockerfile @@ -6,6 +6,6 @@ RUN ./setup.sh ENV JAVA_HOME /opt/openjdk/java17 ENV JDK17 /opt/openjdk/java17 -ENV JDK20 /opt/openjdk/java20 +ENV JDK21 /opt/openjdk/java20 ENV PATH $JAVA_HOME/bin:$PATH diff --git a/ci/images/get-jdk-url.sh b/ci/images/get-jdk-url.sh index 64f7861c09..a054784c10 100755 --- a/ci/images/get-jdk-url.sh +++ b/ci/images/get-jdk-url.sh @@ -8,6 +8,9 @@ case "$1" in java20) echo "https://github.com/bell-sw/Liberica/releases/download/20%2B37/bellsoft-jdk20+37-linux-amd64.tar.gz" ;; + java21) + echo "https://download.java.net/java/early_access/jdk21/18/GPL/openjdk-21-ea+18_linux-x64_bin.tar.gz" + ;; *) echo $"Unknown java version" exit 1 diff --git a/ci/pipeline.yml b/ci/pipeline.yml index 4b7831cfe6..0bcc86b177 100644 --- a/ci/pipeline.yml +++ b/ci/pipeline.yml @@ -127,14 +127,14 @@ resources: access_token: ((github-ci-status-token)) branch: ((branch)) context: build -- name: repo-status-jdk20-build +- name: repo-status-jdk21-build type: github-status-resource icon: eye-check-outline source: repository: ((github-repo-name)) access_token: ((github-ci-status-token)) branch: ((branch)) - context: jdk20-build + context: jdk21-build - name: slack-alert type: slack-notification icon: slack @@ -231,7 +231,7 @@ jobs: "zip.type": "schema" get_params: threads: 8 -- name: jdk20-build +- name: jdk21-build serial: true public: true plan: @@ -239,7 +239,7 @@ jobs: - get: git-repo - get: every-morning trigger: true - - put: repo-status-jdk20-build + - put: repo-status-jdk21-build params: { state: "pending", commit: "git-repo" } - do: - task: check-project @@ -248,16 +248,16 @@ jobs: privileged: true timeout: ((task-timeout)) params: - TEST_TOOLCHAIN: 20 + TEST_TOOLCHAIN: 21 <<: *build-project-task-params on_failure: do: - - put: repo-status-jdk20-build + - put: repo-status-jdk21-build params: { state: "failure", commit: "git-repo" } - put: slack-alert params: <<: *slack-fail-params - - put: repo-status-jdk20-build + - put: repo-status-jdk21-build params: { state: "success", commit: "git-repo" } - name: build-pull-requests serial: true @@ -441,7 +441,7 @@ jobs: groups: - name: "builds" - jobs: ["build", "jdk20-build"] + jobs: ["build", "jdk21-build"] - name: "releases" jobs: ["stage-milestone", "stage-rc", "stage-release", "promote-milestone", "promote-rc", "promote-release", "create-github-release"] - name: "ci-images" diff --git a/ci/scripts/check-project.sh b/ci/scripts/check-project.sh index 6e57231f48..bed54dad6c 100755 --- a/ci/scripts/check-project.sh +++ b/ci/scripts/check-project.sh @@ -4,6 +4,6 @@ set -e source $(dirname $0)/common.sh pushd git-repo > /dev/null -./gradlew -Dorg.gradle.internal.launcher.welcomeMessageEnabled=false -Porg.gradle.java.installations.fromEnv=JDK17,JDK20 \ +./gradlew -Dorg.gradle.internal.launcher.welcomeMessageEnabled=false -Porg.gradle.java.installations.fromEnv=JDK17,JDK21 \ -PmainToolchain=${MAIN_TOOLCHAIN} -PtestToolchain=${TEST_TOOLCHAIN} --no-daemon --max-workers=4 check popd > /dev/null