{{ message }}
Foundation: Java 21 baseline + migration status#19
Open
devin-ai-integration[bot] wants to merge 3 commits into
Open
Foundation: Java 21 baseline + migration status#19devin-ai-integration[bot] wants to merge 3 commits into
devin-ai-integration[bot] wants to merge 3 commits into
Conversation
Co-Authored-By: hitomi.sawamura@gmail.com <hitomi.sawamura@gmail.com>
… issues Co-Authored-By: hitomi.sawamura@gmail.com <hitomi.sawamura@gmail.com>
Co-Authored-By: hitomi.sawamura@gmail.com <hitomi.sawamura@gmail.com>
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Description
This PR establishes the foundation for migrating Apache CloudStack from JDK 11 to JDK 21. It contains three atomic changes:
cs.jdk.version11 → 21 in rootpom.xmlbuild.ymlJDK 17 → 21;trigger-package-and-publish.ymlgets the missing Apache license header and trailing whitespace fixJAVA_21_MIGRATION_STATUS.mdwith module-by-module analysis, deprecated API inventory (253 hits across 9 categories), and a 6-phase rollout planKnown blocker (not fixed here, intentionally):
cglib-nodep 3.3.0does not support JDK 21 class files (major version 65). DAO tests inengine/schemafail withUnsupported class file major version 65. The fix (cglib → ByteBuddy migration) is Phase 2 work.Sandbox build of 25 modules (
mvn install -DskipTests -pl server -am) compiles successfully with JDK 21.Items for reviewer attention
pom.xmlline 58: Verify thatcs.jdk.versionis only used formaven-compiler-pluginsource/target and doesn't have unexpected downstream effectsargLine(pom.xml line 61): Still contains-noverifywhich was removed in JDK 13 — may need follow-upbuild.yml: Was previously JDK 17 whilepom.xmlwas JDK 11; this PR aligns both to 21. Build command (-pl server -am) is unchangedJAVA_21_MIGRATION_STATUS.md: Deprecated API hit counts are based on regex scanning and are approximateTypes of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
Screenshots (if appropriate):
BUILD SUCCESS — 25 modules compiled with JDK 21:

BUILD FAILURE — cglib blocker (

Unsupported class file major version 65):How Has This Been Tested?
mvn install -DskipTests -Dcheckstyle.skip=true -pl server -amwith OpenJDK 21 — BUILD SUCCESS (25 modules, ~78 sec)mvn test -pl engine/schema -Dtest=VMInstanceDaoImplTest -Dcheckstyle.skip=true— BUILD FAILURE confirming the cglib blocker (9 errors, 0 failures)How did you try to break this feature and the system with this change?
Ran a targeted DAO test (
VMInstanceDaoImplTest) to verify JDK 21 test compatibility, which surfaced the cglib-nodep 3.3.0 incompatibility. This blocker is documented inJAVA_21_MIGRATION_STATUS.mdand tracked as Phase 2 work. No application source code was modified.Link to Devin session: https://app.devin.ai/sessions/6199fc8221124d9b88f85d763000e2ab
Requested by: @hitomimimi