Migrate Java 8 to Java 21: update build configs, CI/CD, and documentation - #35
Open
devin-ai-integration[bot] wants to merge 1 commit into
Open
devin-ai-integration[bot] wants to merge 1 commit into
devin-ai-integration[bot] wants to merge 1 commit into
Conversation
…tion - Update maven-compiler-plugin from 3.5.1 to 3.11.0 with source/target 21 (root pom.xml) - Update PatentDocument maven-compiler-plugin from 3.8.0 to 3.11.0, java version property to 21 - Add java.version=21 property to root pom.xml - Update GitHub Actions workflow to use JDK 21 (from JDK 17) - Update sonar-project.properties java source/target from 8 to 21 - Add Java 21 requirements section to README.md Co-Authored-By: Joao Esteves <joao.esteves@cognition.ai>
Contributor
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.
Migrate Java 8 to Java 21: build configs, CI, and docs
Summary
Migrates the project from Java 8 to Java 21 across all build configuration, CI/CD, static analysis settings, and documentation.
Changes by file:
pom.xml(root): Added<java.version>21</java.version>property, upgradedmaven-compiler-plugin3.5.1 → 3.11.0, changed<source>/<target>from1.8to21PatentDocument/pom.xml: Changedproject.java.versionproperty from1.8to21, upgradedmaven-compiler-plugin3.8.0 → 3.11.0.github/workflows/sonarcloud.yml: Updatedsetup-javafrom JDK 17 to JDK 21sonar-project.properties: Updatedsonar.java.sourceandsonar.java.targetfrom8to21README.md: Added Requirements section (Java 21+, Maven 3.9+)No code changes required: All
javax.*imports are either part of JDK core modules still present in Java 21 (java.xml,java.naming) or backed by explicit Maven dependencies (jaxb-api,jaxb-runtime,javax.json). Nosun.misc/sun.reflectusage found.Pre-existing test failures: 3 tests in PatentDocument fail identically on
master— not caused by this migration.Review & Testing Checklist for Human
BulkDownloaderusesjavax.xml.bindimports (removed from JDK in Java 11). Explicitjaxb-api+jaxb-runtimedependencies exist, but confirm JAXB unmarshalling works at runtime (e.g.,Sources.javaloading XML config)Cp1252encoding still works:PatentDocument/pom.xmlusesCp1252source encoding — unusual but compiled successfully. Worth a spot-check that patent document parsing behaves correctly with Java 21java.versionproperty in root pom.xml is informational only — the root compiler plugin hardcodes<source>21</source>directly rather than referencing${java.version}.PatentDocumentdoes reference its property correctly via${project.java.version}. Decide if you want consistency here.Recommended test plan: Run the BulkDownloader module's main entry points that exercise JAXB (XML source config loading) and XPath operations to confirm runtime compatibility beyond just compilation.
Notes
.gitlab-ci.ymlwere present in the repo