chore: Java 17 migration (Phases 1-3) - build config, CI, and dependency upgrades#351
Open
devin-ai-integration[bot] wants to merge 2 commits intomasterfrom
Open
chore: Java 17 migration (Phases 1-3) - build config, CI, and dependency upgrades#351devin-ai-integration[bot] wants to merge 2 commits intomasterfrom
devin-ai-integration[bot] wants to merge 2 commits intomasterfrom
Conversation
- Update Java source/target compatibility from 11 to 17 - Upgrade Spring Boot from 2.6.3 to 2.7.18 - Upgrade Netflix DGS codegen plugin from 5.0.6 to 6.0.3 - Upgrade Netflix DGS from 4.9.21 to 5.5.1 - Upgrade MyBatis from 2.2.2 to 2.3.2 - Upgrade JJWT from 0.11.2 to 0.12.5 - Upgrade Joda-Time from 2.10.13 to 2.12.7 - Upgrade SQLite JDBC from 3.36.0.3 to 3.45.0.0 - Upgrade REST Assured from 4.5.1 to 5.4.0 - Update CI pipeline to use JDK 17 Co-Authored-By: Vedant Khanna <vedantkhanna@gmail.com>
- Fix PageInfo type mismatch: use DGS-generated PageInfo instead of graphql.relay.DefaultPageInfo - Fix JJWT 0.12.x API changes: update to new builder/parser methods - Fix JJWT key handling: use Keys.hmacShaKeyFor() for proper key size detection - Fix graphql-java version: force 19.2 for federation-graphql-java-support compatibility - Fix REST Assured version: add explicit rest-assured-common and spring-commons 5.4.0 Co-Authored-By: Vedant Khanna <vedantkhanna@gmail.com>
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.
Java 17 Migration (Phases 1-3)
Summary
Migrates the project from Java 11 to Java 17, upgrading Spring Boot from 2.6.3 → 2.7.18 and all major dependencies. Includes source code fixes required by breaking API changes in JJWT 0.12.x and Netflix DGS 5.5.1.
Build config changes (
build.gradle,.github/workflows/gradle.yml):graphql-java:19.2to resolve federation compatibility)rest-assured-commonandspring-commonsto prevent Spring BOM downgrade)Source code fixes:
DefaultJwtService: migrated from deprecated JJWT 0.11 API (parserBuilder,setSubject,parseClaimsJws,getBody) to 0.12 API (parser,subject,parseSignedClaims,getPayload). Switched key creation fromSecretKeySpec+SignatureAlgorithm.HS512toKeys.hmacShaKeyFor().ArticleDatafetcher/CommentDatafetcher: replacedgraphql.relay.DefaultPageInfowith DGS-generatedio.spring.graphql.types.PageInfoto fix type incompatibility introduced by DGS 5.5.1.Review & Testing Checklist for Human
Keys.hmacShaKeyFor()auto-selects HMAC algorithm based on key byte length (HS256 for 32-47 bytes, HS384 for 48-63, HS512 for 64+). The old code hardcoded HS512. Verify the productionjwt.secretvalue is ≥64 bytes, otherwise the signing algorithm silently downgrades and all existing tokens become invalid after deployment.federation-graphql-java-support. Test GraphQL queries/mutations manually to ensure no runtime issues../gradlew bootRun) and verify REST API endpoints work (e.g.,curl http://localhost:8080/tags, user registration/login, article CRUD).PageInfotype change affectshasPreviousPage/hasNextPagefield names.Notes