Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(Linux): switch supported architectures to GA Temurin jdk21 images #521

Merged
merged 27 commits into from
Oct 22, 2023

Conversation

lemeurherve
Copy link
Member

@lemeurherve lemeurherve commented Oct 12, 2023

This PR switch supported architectures (x86 & arm64) to the GA jdk21 Temurin Linux images.

It keeps jdk21-preview images for unsupported architectures (ppc64le, arm32 and s390x).

It also include a fix for the preview (EA) release download URL.

Follow-up of #518

Depending on #520 decision about archlinux, I could add an archlinux-jdk21 image too. removed from that PR.

Testing done

https://ci.jenkins.io/job/Packaging/job/docker-agent/job/PR-521/32/

Submitter checklist

Copy link
Contributor

@gounthar gounthar left a comment

Choose a reason for hiding this comment

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

Maybe we should wait, then, until they become available.

@lemeurherve
Copy link
Member Author

lemeurherve commented Oct 12, 2023

Maybe we should wait, then, until they become available.

I can rework my PR to keep linux-arm32 and linux-ppc64le as jdk21-preview images, WDYT?

EDIT: done.

Copy link
Member

@timja timja left a comment

Choose a reason for hiding this comment

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

use a multi-arch image to retrieve the jdk please instead of fetching it via wget like we do in all other images

I was looking at an old diff

docker-bake.hcl Show resolved Hide resolved
"${REGISTRY}/${JENKINS_REPO}:latest-bookworm-jdk21",
"${REGISTRY}/${JENKINS_REPO}:latest-jdk21",
]
platforms = ["linux/amd64", "linux/arm64"]
Copy link
Member

Choose a reason for hiding this comment

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

I would probably just wait a couple of days they probably won't take long to produce the other platforms?

@lemeurherve
Copy link
Member Author

lemeurherve commented Oct 12, 2023

Maybe we should wait, then, until they become available.

I can rework my PR to keep linux-arm32 and linux-ppc64le as jdk21-preview images, WDYT?

EDIT: done.

There aren't any binaries for these architectures in recent releases (https://github.com/adoptium/temurin21-binaries/releases).

To keep preview images for these specific architecture without blocking the major ones, I propose to use the (fixed) last release where they're available in

RUN set -x; apt-get update \
&& apt-get install --no-install-recommends -y \
ca-certificates \
jq \
wget \
&& BUILD_NUMBER=$(echo $JAVA_VERSION | cut -d'+' -f2) \
&& JAVA_MAJOR_VERSION=$(echo $JAVA_VERSION | cut -d'+' -f1) \
&& JAVA_VERSION_ENCODED=$(echo "$JAVA_VERSION" | jq "@uri" -jRr) \
&& CONVERTED_ARCH=$(arch | sed -e 's/x86_64/x64/' -e 's/armv7l/arm/') \
&& wget --quiet https://github.com/adoptium/temurin"${JAVA_MAJOR_VERSION}"-binaries/releases/download/jdk-"${JAVA_VERSION_ENCODED}"-ea-beta/OpenJDK"${JAVA_MAJOR_VERSION}"U-jdk_"${CONVERTED_ARCH}"_linux_hotspot_ea_"${JAVA_MAJOR_VERSION}"-0-"${BUILD_NUMBER}".tar.gz -O /tmp/jdk.tar.gz \
&& tar -xzf /tmp/jdk.tar.gz -C /opt/ \
&& rm -f /tmp/jdk.tar.gz

WDYT?

@lemeurherve
Copy link
Member Author

We can also wait a few days.

@timja
Copy link
Member

timja commented Oct 12, 2023

We can also wait a few days.

I would prefer to just wait a few days they should come out soon

@gounthar
Copy link
Contributor

gounthar commented Oct 12, 2023

Thank you.
Here is the current status found here.
image

⛔ means there is no build planned for that version/platform combination. 🤔
Could we wait for arm32, ppc64le and x64 Windows to go?

There is an explanation in a Temurin repo where they describe the different classes of platforms they support.
I guess s390x is in the last group.

Quote from Temurin, a few minutes ago:

As things stand we are unable to ship a JDK21 build for s390x. We are hopeful that we might be able to ship a build of 21.0.1 with support for s390x

@lemeurherve
Copy link
Member Author

lemeurherve commented Oct 12, 2023

Thank you. Here is the current status found here.

Thanks for the link, quite useful!

Could we wait for arm32, ppc64le [...] to go?

Yes, I'll keep this PR as draft until arm32 & ppc64le images variants are ready.

and x64 Windows

Unrelated to this PR concerning Linux images.

We're already publishing amd64 Windows images (see https://hub.docker.com/r/jenkins/agent/tags?page=1&name=21), which AFAIU are the same architecture.

I can't find the right link at the moment, but there is an explanation somewhere in a Temurin repo where they describe the different classes of platforms they support. I guess s390x is in the last group.

I've removed s390x target architecture for jdk21 as it won't be supported in commit 2d4b319

@lemeurherve
Copy link
Member Author

adoptium/temurin#8 has been closed, and the October release status doesn't look good for the architectures we were waiting for: adoptium/temurin#6

image

With these new elements at hand, are you OK if I restore a similar workaround as the one deployed in jenkinsci/docker#1738 to keep the preview tags/images like in 2eae836?

@MarkEWaite
Copy link
Contributor

I think that the workaround is a very reasonable compromise.

@dduportal
Copy link
Contributor

+1 with the workaround! Will be double justified as there is a ne EA release for s390x for instance, as pointed by @gounthar : https://github.com/adoptium/temurin21-binaries/releases/tag/jdk-21.0.1%2B12-ea-beta

@gounthar
Copy link
Contributor

Yes, ppc64le, s390x and armv7 are available for the JDK 21.0.1 early access.

@lemeurherve
Copy link
Member Author

I'll prepare the workaround, then as follow-up of this PR I'll prepare another one for updatecli manifests managing both type of versions like jenkinsci/docker#1741

…clipse-temurin:21 image" "also remove linux-s390x for jdk21" "remove linux-arm32 and linux-ppc64le architectures for jdk21, unavailable in eclipse-temurin images""

This reverts commit 3a9d480.
@lemeurherve lemeurherve changed the title feat(Linux): add Java 21 feat(Linux): switch supported architectures to GA Temurin jdk21 images Oct 22, 2023
@lemeurherve lemeurherve marked this pull request as ready for review October 22, 2023 17:15
@lemeurherve lemeurherve requested a review from a team as a code owner October 22, 2023 17:15
@lemeurherve
Copy link
Member Author

Included back the workaround, and also incorporated the same kind of preview (EA) release download URL fix as jenkinsci/docker#1747

PR ready for review, to be squashed.

@lemeurherve
Copy link
Member Author

I'll prepare the workaround, then as follow-up of this PR I'll prepare another one for updatecli manifests managing both type of versions like jenkinsci/docker#1741

Updatecli manifests update addressed in #536

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants