You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tez.apache.org by ay...@apache.org on 2025/06/20 07:36:39 UTC

(tez) branch master updated: TEZ-4636: Move to JDK-21+ (#418). (Ayush Saxena, reviewed by Laszlo Bodor, Mahesh Raju Somalaraju)

This is an automated email from the ASF dual-hosted git repository.

ayushsaxena pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tez.git


The following commit(s) were added to refs/heads/master by this push:
     new 03b5f1d68 TEZ-4636: Move to JDK-21+ (#418). (Ayush Saxena, reviewed by Laszlo Bodor, Mahesh Raju Somalaraju)
03b5f1d68 is described below

commit 03b5f1d68ed30d214d0a0aa3e6ec9fe67777372d
Author: Ayush Saxena <ay...@apache.org>
AuthorDate: Fri Jun 20 13:06:34 2025 +0530

    TEZ-4636: Move to JDK-21+ (#418). (Ayush Saxena, reviewed by Laszlo Bodor, Mahesh Raju Somalaraju)
---
 .github/workflows/build.yml   |  2 +-
 Jenkinsfile                   |  4 ++--
 build-tools/docker/Dockerfile | 20 +++++++++-----------
 pom.xml                       |  7 ++++---
 4 files changed, 16 insertions(+), 17 deletions(-)

diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 1148df52c..22a8a3711 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -27,7 +27,7 @@ jobs:
   build:
     strategy:
       matrix:
-        java-version: [17]
+        java-version: [21, 24]
         os: [ubuntu-latest, macos-latest]
     runs-on: ${{ matrix.os }}
     steps:
diff --git a/Jenkinsfile b/Jenkinsfile
index aa6263fa2..f3f895f31 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -147,8 +147,8 @@ pipeline {
                         # help keep the ASF boxes clean
                         YETUS_ARGS+=("--sentinel")
 
-                        # test with Java 17
-                        YETUS_ARGS+=("--java-home=/usr/lib/jvm/java-17-openjdk-amd64")
+                        # test with Java 21
+                        YETUS_ARGS+=("--java-home=/usr/lib/jvm/java-21-openjdk-amd64")
                         YETUS_ARGS+=("--debug")
 
                         # write Yetus report as GitHub comment (YETUS-1102)
diff --git a/build-tools/docker/Dockerfile b/build-tools/docker/Dockerfile
index d4cc574ed..1e7131e5f 100644
--- a/build-tools/docker/Dockerfile
+++ b/build-tools/docker/Dockerfile
@@ -24,7 +24,7 @@
 #
 ###############
 
-FROM ubuntu:jammy AS tezbase
+FROM ubuntu:noble AS tezbase
 
 WORKDIR /root
 SHELL ["/bin/bash", "-o", "pipefail", "-c"]
@@ -168,15 +168,15 @@ SHELL ["/bin/bash", "-o", "pipefail", "-c"]
 # OpenJDK 17
 # hadolint ignore=DL3008
 RUN apt-get -q update \
-    && DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y openjdk-17-jdk \
+    && DEBIAN_FRONTEND=noninteractive apt-get install --no-install-recommends -y openjdk-21-jdk \
     && apt-get clean && rm -rf /var/lib/apt/lists/*
 
 # Set JAVA_HOME and PATH environment variables
-ENV JAVA_HOME=/usr/lib/jvm/java-17-openjdk-amd64
+ENV JAVA_HOME=/usr/lib/jvm/java-21-openjdk-amd64
 ENV PATH="${JAVA_HOME}/bin:${PATH}"
 
 # Set the default Java version using update-alternatives
-RUN update-alternatives --install /usr/bin/java java /usr/lib/jvm/java-17-openjdk-amd64/bin/java 1
+RUN update-alternatives --install /usr/bin/java java /usr/lib/jvm/java-21-openjdk-amd64/bin/java 1
 
 #######
 # Install SpotBugs 4.9.3
@@ -223,9 +223,9 @@ RUN apt-get -q update && apt-get -q install --no-install-recommends -y \
     && apt-get clean \
     && rm -rf /var/lib/apt/lists/* \
     && curl -sSL https://bootstrap.pypa.io/get-pip.py -o /tmp/get-pip.py \
-    && python3 /tmp/get-pip.py \
+    && python3 /tmp/get-pip.py --break-system-packages \
     && rm /usr/local/bin/pip /tmp/get-pip.py \
-    && pip3 install -v \
+    && pip3 install --break-system-packages -v \
         astroid==2.4.2 \
         codespell==2.0 \
         pylint==2.5.3 \
@@ -239,14 +239,12 @@ RUN ln -s /usr/local/bin/pip3 /usr/local/bin/pip
 # Install npm and JSHint
 ###
 # hadolint ignore=DL3008
-RUN curl -sSL https://deb.nodesource.com/setup_14.x | bash - \
-    && apt-get -q install --no-install-recommends -y nodejs \
-    && apt-get clean \
-    && rm -rf /var/lib/apt/lists/* \
+RUN apt-get update && apt-get install --no-install-recommends -y nodejs npm \
     && npm install -g \
         jshint@2.12.0 \
         markdownlint-cli@0.23.2 \
-    && rm -rf /root/.npm
+    && apt-get clean \
+    && rm -rf /var/lib/apt/lists/* /root/.npm
 
 #####
 # Now all the stuff that was built in parallel
diff --git a/pom.xml b/pom.xml
index 93f761ec5..8dfdec9ec 100644
--- a/pom.xml
+++ b/pom.xml
@@ -41,8 +41,8 @@
 
   <properties>
     <!-- Build Properties -->
-    <maven.compiler.source>17</maven.compiler.source>
-    <maven.compiler.target>17</maven.compiler.target>
+    <maven.compiler.source>21</maven.compiler.source>
+    <maven.compiler.target>21</maven.compiler.target>
     <maven.test.redirectTestOutputToFile>true</maven.test.redirectTestOutputToFile>
     <surefire.version>3.0.0-M4</surefire.version>
     <failIfNoTests>false</failIfNoTests>
@@ -88,7 +88,7 @@
     <maven-shade-plugin.version>3.6.0</maven-shade-plugin.version>
     <maven-site-plugin.version>3.12.1</maven-site-plugin.version>
     <metrics-core.version>3.1.0</metrics-core.version>
-    <mockito-core.version>4.3.1</mockito-core.version>
+    <mockito-core.version>4.8.1</mockito-core.version>
     <netty.version>4.1.116.Final</netty.version>
     <pig.version>0.13.0</pig.version>
     <protobuf.version>3.25.5</protobuf.version>
@@ -106,6 +106,7 @@
       --add-opens=java.base/java.lang=ALL-UNNAMED
       --add-opens=java.base/java.util=ALL-UNNAMED
       --add-opens java.base/java.io=ALL-UNNAMED
+      -Dnet.bytebuddy.experimental=true
     </test.jvm.args>
 
     <maven.javadoc.skip>true</maven.javadoc.skip> <!-- enabled only in relevant modules separately -->