Migrate from Java 11 + Spring Boot 2.6.3 to Java 17 + Spring Boot 3.2.0#358
Open
devin-ai-integration[bot] wants to merge 1 commit intomasterfrom
Open
Migrate from Java 11 + Spring Boot 2.6.3 to Java 17 + Spring Boot 3.2.0#358devin-ai-integration[bot] wants to merge 1 commit intomasterfrom
devin-ai-integration[bot] wants to merge 1 commit intomasterfrom
Conversation
- Update Java source/target compatibility to 17 - Upgrade Spring Boot to 3.2.0, dependency-management to 1.1.4 - Upgrade Gradle wrapper from 7.4 to 8.5 (Java 21 support) - Upgrade Netflix DGS codegen to 6.0.3, DGS starter to 8.2.0 - Upgrade MyBatis Spring Boot starter to 3.0.3 - Upgrade REST Assured to 5.3.2 - Migrate javax.* to jakarta.* imports (servlet, validation) - Refactor WebSecurityConfig: remove WebSecurityConfigurerAdapter, use SecurityFilterChain bean with lambda DSL - Update requestMatchers (was antMatchers), authorizeHttpRequests (was authorizeRequests) - Fix CustomizeExceptionHandler for HttpStatusCode signature change - Fix GraphQLCustomizeExceptionHandler for new handleException API - Fix PageInfo type to use DGS-generated types instead of graphql-relay - Update CI workflow to JDK 17 - Update README to reflect Java 17 requirement Co-Authored-By: Ian Moritz <ian.moritz@cognition.ai>
Author
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
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.
Summary
Major framework upgrade migrating from Java 11 / Spring Boot 2.6.3 to Java 17 / Spring Boot 3.2.0. This touches 27 files across build config, CI, security, and all Jakarta EE namespace imports.
Key changes:
javax.servlet.*,javax.validation.*→jakarta.servlet.*,jakarta.validation.*(20 files).javax.cryptoleft as-is (JDK, not Jakarta EE).WebSecurityConfigurerAdapterremoved →SecurityFilterChain@Beanwith lambda DSL.antMatchers→requestMatchers,authorizeRequests→authorizeHttpRequests.CustomizeExceptionHandler.handleMethodArgumentNotValidsignature updated (HttpStatus→HttpStatusCode).DataFetcherExceptionHandler.onException→handleExceptionreturningCompletableFuture.graphql.relay.DefaultPageInfo→ DGS-generatedio.spring.graphql.types.PageInfobuilder pattern.Review & Testing Checklist for Human
WebSecurityConfiglambda DSL produces identical security behavior to the oldWebSecurityConfigurerAdapterchain — especially CORS handling (now passed viacors(cors -> cors.configurationSource(...))instead of.cors().and()) and URL matching (requestMatchersvsantMatcherscan differ in pattern semantics)../gradlew clean test). Compilation passes but tests were not run locally. MyBatis 2→3, DGS 4→8, and Spring Security 5→6 all have potential runtime/test-level breaking changes.graphql.relay.DefaultPageInfoto the DGS-generatedPageInfobuilder assumes the schema generatesstartCursor,endCursor,hasPreviousPage,hasNextPage. Confirm the generated types match../gradlew bootRun) and hit a few endpoints (e.g.,GET /tags,POST /users, GraphQL at/graphql) to verify Spring context loads and DGS wiring is correct.Notes
javax.crypto.SecretKey/SecretKeySpecimports inDefaultJwtService.javawere intentionally not migrated — these are JDK classes, not Jakarta EE.Link to Devin run: https://app.devin.ai/sessions/e5a65850f33e460b8925a594dbcaac23
Requested by: @iancmoritz