Skip to content

Conversation

@devin-ai-integration
Copy link

Upgrade Java from 17 to 22

Summary

This PR upgrades the Spring Boot banking application from Java 17 to Java 22, updating all related configuration files, dependencies, and Docker images. The changes include:

  • Java version: 17 → 22 in pom.xml properties
  • Spring Boot: 3.3.3 → 3.5.6 (required for Java 22 support)
  • Maven compiler plugin: source/target 1.8 → 22
  • MySQL connector: Replaced deprecated mysql-connector-java with mysql-connector-j
  • Docker images: Updated to maven:3.9-eclipse-temurin-22 and eclipse-temurin:22-alpine
  • Documentation: Updated Jenkins installation instructions to use openjdk-22-jre

Docker build was successfully verified with Java 22 images.

Review & Testing Checklist for Human

This is a medium-risk change due to significant version upgrades. Please verify:

  • Application starts successfully and connects to MySQL database
  • All Spring Boot features work: authentication, web endpoints, database operations, Thymeleaf templates
  • MySQL connector compatibility: Test database queries, transactions, and connection pooling
  • Docker containers run properly: Build and run both development and production Docker setups
  • CI/CD pipeline compatibility: Ensure all build and deployment processes still work with Java 22

Notes

  • Java 22 is not an LTS release (Java 21 is the latest LTS). Consider long-term support implications.
  • Spring Boot 3.5.6 was chosen as the latest stable version with confirmed Java 22 support.
  • Local testing was limited due to Java 22 not being available in the development environment.

Link to Devin run: https://app.devin.ai/sessions/50b8fb29d75c4c92b0e4742860058f44
Requested by: @satwik-cog

- Update Java version property to 22 in pom.xml
- Upgrade Spring Boot parent version from 3.3.3 to 3.5.6 for Java 22 support
- Update Maven compiler plugin source/target to 22
- Replace deprecated mysql-connector-java with mysql-connector-j
- Update Dockerfile build stage to maven:3.9-eclipse-temurin-22
- Update Dockerfile runtime stage to eclipse-temurin:22-alpine
- Update Jenkins installation instructions to use openjdk-22-jre in README files

Verified with successful Docker build using Java 22 images.

Co-Authored-By: Satwik Bebortha <satwik.bebortha@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.

1 participant