Skip to content

TEDEFO-5287 Build and target Java 21 instead of Java 11 - #74

Open
amiliosc wants to merge 1 commit into
developfrom
feature/TEDEFO-5287-build-and-target-java-21
Open

amiliosc wants to merge 1 commit into
developfrom
feature/TEDEFO-5287-build-and-target-java-21

Conversation

@amiliosc

Copy link
Copy Markdown

Summary

Moves the library from Java 11 to Java 21. Build configuration and CI only —
no source changes were needed, the existing sources compile unchanged.

  • pom.xml: java.version 11 → 21; maven.compiler.source/target replaced
    by maven.compiler.release, which also rejects references to APIs newer than
    the target
  • pom.xml: pinned maven-compiler-plugin in pluginManagement (the
    version.compiler.plugin property existed but was wired to no plugin, so the
    version was floating); JaCoCo 0.8.10 → 0.8.12 for Java 21 bytecode
  • CI: java-version: 21 in the three workflows, and distribution: adopt →
    temurin since adopt is deprecated and publishes no Java 21 builds
  • README: Java version requirement updated in both places

Tested

mvn clean install on Temurin 21.0.12 — compiled at release 21, 99/99 tests
green, jar built.

japicmp could not be run locally: it fetched an EU Login HTML page instead of
the baseline jar through the corporate proxy, so the run used
-Djapicmp.skip=true. The API-compatibility check needs to pass in CI here.

Note for reviewers

This raises the bytecode level of a published artifact, so every consumer must
be on Java 21 before taking the release — a major-version change under semver.
Jira targets ECL 2.0.0 for that reason.

A stale origin/java21 branch (June 2025) reached the same pom conclusions
independently; it predates a year of develop and should probably be deleted.
It also bumps maven-source-plugin to 3.3.1, which this branch does not.

Jira: TEDEFO-5287

@amiliosc
amiliosc requested a review from rousso October 19, 2026 16:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant