Skip to content

Upgrade from Java 17 to Java 21#90

Open
devin-ai-integration[bot] wants to merge 1 commit intoDevOpsfrom
devin/1769080075-java-21-upgrade
Open

Upgrade from Java 17 to Java 21#90
devin-ai-integration[bot] wants to merge 1 commit intoDevOpsfrom
devin/1769080075-java-21-upgrade

Conversation

@devin-ai-integration
Copy link

Summary

This PR upgrades the application from Java 17 to Java 21, updating all relevant configuration files:

  • pom.xml: Updated java.version property to 21, upgraded maven-compiler-plugin to 3.11.0 with source/target 21 (previously was inconsistently set to 1.8)
  • Dockerfile: Updated build stage to maven:3.9-eclipse-temurin-21 and runtime stage to eclipse-temurin:21-jre-alpine (switched from openjdk to Eclipse Temurin distribution)
  • README.md: Updated Jenkins installation instructions to use openjdk-21-jre

The application compiles successfully with Java 21. Spring Boot 3.3.3 and all dependencies are compatible with Java 21.

Review & Testing Checklist for Human

  • Build and run the Docker image - Verify the new Eclipse Temurin base images work correctly and the application starts
  • Test in staging environment - Run the application with a MySQL database to verify full functionality (local tests couldn't run due to missing database)
  • Verify CI/CD pipelines - Ensure Jenkins and other CI tools work with Java 21
  • Check for runtime behavior changes - Java 21 has some behavioral changes from Java 17; verify critical application flows work as expected

Recommended test plan: Deploy to a staging environment, run smoke tests against the banking application endpoints, and verify database operations work correctly.

Notes

  • The maven-compiler-plugin was previously configured with source/target 1.8 (inconsistent with java.version 17). This has been corrected to 21.
  • Switched from openjdk Docker images to eclipse-temurin as recommended by the playbook (openjdk:21-alpine may not be available)

Link to Devin run: https://app.devin.ai/sessions/9096055e1a52410fb43b243a6dd5112f
Requested by: Joao Esteves (@joao-cognition)

- Update java.version property from 17 to 21 in pom.xml
- Update maven-compiler-plugin to version 3.11.0 with source/target 21
- Update Dockerfile build stage from maven:3.8.3-openjdk-17 to maven:3.9-eclipse-temurin-21
- Update Dockerfile runtime stage from openjdk:17-alpine to eclipse-temurin:21-jre-alpine
- Update README.md Jenkins installation to use openjdk-21-jre

Co-Authored-By: Joao Esteves <joao.esteves@cognition.ai>
@devin-ai-integration
Copy link
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 and CI 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.

0 participants