Skip to content

Comments

Upgrade from Java 11 to Java 17 with Spring Boot 3.2.5#367

Open
devin-ai-integration[bot] wants to merge 1 commit intomasterfrom
devin/1771605535-java-17-upgrade
Open

Upgrade from Java 11 to Java 17 with Spring Boot 3.2.5#367
devin-ai-integration[bot] wants to merge 1 commit intomasterfrom
devin/1771605535-java-17-upgrade

Conversation

@devin-ai-integration
Copy link

@devin-ai-integration devin-ai-integration bot commented Feb 20, 2026

Upgrade Java 11 → 17 with Spring Boot 3.2.5

Summary

Complete migration from Java 11 / Spring Boot 2.6.3 to Java 17 / Spring Boot 3.2.5, including all dependency upgrades and breaking API changes. All 69 existing tests pass.

Key version changes:

Component Before After
Java 11 17
Spring Boot 2.6.3 3.2.5
Gradle 7.4 8.7
DGS GraphQL 4.9.21 8.5.5
JJWT 0.11.2 0.12.5
MyBatis Starter 2.2.2 3.0.3
Rest-Assured 4.5.1 5.4.0
SQLite JDBC 3.36.0.3 3.45.3.0

Code changes:

  • javax.*jakarta.* namespace migration across all source files
  • WebSecurityConfig: removed WebSecurityConfigurerAdapter, now uses SecurityFilterChain bean with lambda DSL; antMatchersrequestMatchers
  • DefaultJwtService: migrated to JJWT 0.12.x API (subject()/expiration()/parseSignedClaims()); key derivation now hashes secret via SHA-512 to meet JJWT 0.12's minimum key size requirements
  • GraphQLCustomizeExceptionHandler: onExceptionhandleException returning CompletableFuture
  • ArticleDatafetcher/CommentDatafetcher: graphql.relay.DefaultPageInfo → generated io.spring.graphql.types.PageInfo
  • CustomizeExceptionHandler: HttpStatusHttpStatusCode parameter in overridden method
  • CI workflow updated to JDK 17

Review & Testing Checklist for Human

  • JWT key derivation changedDefaultJwtService now SHA-512 hashes the secret before creating the HMAC key. This means any existing JWT tokens from a running deployment will be invalidated after this upgrade. Verify this is acceptable for your deployment strategy, or plan a coordinated token rotation.
  • Security filter chain rules — Verify the requestMatchers ordering in WebSecurityConfig preserves the intended auth behavior, especially that GET /articles/feed (authenticated) is evaluated before GET /articles/** (permitAll).
  • DGS 8.x runtime behavior — The DGS jump from 4.x to 8.x is large. Manually test GraphQL queries (articles, comments, user mutations) and verify pagination (PageInfo fields: hasNextPage, hasPreviousPage, startCursor, endCursor) works correctly end-to-end.
  • Run full test suite locally with Java 17 to confirm CI results: ./gradlew clean test

Notes


Open with Devin

- Update Java sourceCompatibility/targetCompatibility from 11 to 17
- Upgrade Spring Boot from 2.6.3 to 3.2.5
- Upgrade Gradle wrapper from 7.4 to 8.7
- Upgrade Spring dependency management plugin to 1.1.5
- Migrate all javax.* imports to jakarta.* (validation, servlet)
- Rewrite WebSecurityConfig: remove WebSecurityConfigurerAdapter, use SecurityFilterChain bean with lambda DSL
- Update Spring Security: antMatchers -> requestMatchers, authorizeRequests -> authorizeHttpRequests
- Update CustomizeExceptionHandler for Spring Boot 3 (HttpStatusCode parameter)
- Upgrade JJWT from 0.11.2 to 0.12.5 with new API (subject/expiration/parseSignedClaims)
- Fix JWT key generation to use SHA-512 digest for JJWT 0.12.x key size requirements
- Upgrade DGS GraphQL from 4.9.21 to 8.5.5 with API changes (handleException, CompletableFuture)
- Fix PageInfo type: use generated io.spring.graphql.types.PageInfo instead of graphql.relay.PageInfo
- Upgrade MyBatis starter from 2.2.2 to 3.0.3
- Upgrade Rest-Assured from 4.5.1 to 5.4.0
- Upgrade SQLite JDBC from 3.36.0.3 to 3.45.3.0
- Upgrade DGS codegen plugin from 5.0.6 to 6.2.1
- Upgrade Spotless plugin from 6.2.1 to 6.25.0
- Update CI workflow to use JDK 17
- All 69 existing tests pass

Co-Authored-By: Lukas Burger <lukas.burger@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

Copy link
Author

@devin-ai-integration devin-ai-integration bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no potential bugs to report.

View in Devin Review to see 5 additional findings.

Open in Devin Review

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