Skip to content

Migrate from Java 17 to Java 21#261

Open
devin-ai-integration[bot] wants to merge 1 commit into
DevOpsfrom
devin/1782396144-java21-migration
Open

Migrate from Java 17 to Java 21#261
devin-ai-integration[bot] wants to merge 1 commit into
DevOpsfrom
devin/1782396144-java21-migration

Conversation

@devin-ai-integration

@devin-ai-integration devin-ai-integration Bot commented Jun 25, 2026

Copy link
Copy Markdown

Summary

Upgrades the build/runtime target from Java 17 to Java 21. The Spring Boot parent (3.3.3) already supports 21, so no dependency changes were needed.

pom.xml

  • <java.version>17</java.version>21
  • Fixed the maven-compiler-plugin: it had a stale <source>1.8</source>/<target>1.8</target> (and a hardcoded <version>3.8.0</version>). Both the explicit source/target and the version are now removed so the plugin inherits the version from the Spring Boot parent and the release from java.version (compiler now runs with release 21).

Dockerfile

  • Builder: maven:3.8.3-openjdk-17maven:3.9-eclipse-temurin-21
  • Deployer: openjdk:17-alpineeclipse-temurin:21-jre-alpine (the openjdk images are deprecated and have no 21-alpine tag)

Verification

  • ./mvnw clean install with JDK 21: BUILD SUCCESS, compiled with release 21, Tests run: 1, Failures: 0, Errors: 0 (against a live MySQL).
  • docker build .: both stages build successfully on the new base images.

Kubernetes manifests (kubernetes/) and Helm charts (helm/bankapp/) reference the container image, not a Java version, and contain no hardcoded JDK base-image tags — left unchanged.

Link to Devin session: https://app.devin.ai/sessions/ca7656e2aa9740fabbff35d379ec17ed
Requested by: @joao-cognition


Devin Review

Status Commit
⚪ Not started

Run Devin Review

Open in Devin Review (Staging)

@devin-ai-integration

Copy link
Copy Markdown
Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment, CI, and merge conflict monitoring

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