Skip to content

feature: upgrade build from Java 9 to Java 17 (LTS)#5

Open
devin-ai-integration[bot] wants to merge 1 commit into
masterfrom
devin/1782486168-upgrade-java17
Open

feature: upgrade build from Java 9 to Java 17 (LTS)#5
devin-ai-integration[bot] wants to merge 1 commit into
masterfrom
devin/1782486168-upgrade-java17

Conversation

@devin-ai-integration

@devin-ai-integration devin-ai-integration Bot commented Jun 26, 2026

Copy link
Copy Markdown

Summary

Upgrades this educational Maven project's toolchain from Java 9 to Java 17 (LTS). The build was previously pinned to 1.9 and used plugin/dependency versions that predate JDK 17 support. mvn clean verify now passes on JDK 17 with no source-code changes required — all the Streams/Lambda/CompletableFuture examples compile unmodified.

pom.xml changes

  • Compiler target 1.9 → 17: replaced the maven-compiler-plugin <source>1.9</source>/<target>1.9</target> with a single <release>17</release> (also surfaced as the maven.compiler.release property).
  • maven-compiler-plugin 3.1 → 3.11.0: 3.1 cannot emit class file version 61 / doesn't understand <release>.
  • maven-shade-plugin: pinned to 3.4.1 (was unversioned, which resolved to an ancient default that fails on JDK 17's ASM/bytecode level). The benchmark uber-jar (benchmarks.jar) still builds.
  • JMH 1.17.4 → 1.37 (via a jmh.version property): older JMH bundles an ASM that rejects Java 17 bytecode during annotation processing.
  • JUnit 4.11 → 4.13.2: small bump for a JDK 17–clean test dependency.
  • Added dependency-reduced-pom.xml (generated by the shade plugin) to .gitignore.

Code changes

None. No examples used APIs removed/changed after Java 9, so no migration edits were needed.

Validation

mvn clean verify on java -version = 17.0.19 → BUILD SUCCESS. The repo has no src/test test classes, so there were no existing tests to run; surefire reported no tests and the build (incl. shade packaging) completes cleanly.

Residual risks

  • No automated tests exist in the repo, so validation is limited to successful compilation + packaging.
  • The shade plugin logs benign "overlapping resources" (LICENSE / MANIFEST.MF) warnings from the JMH/JUnit jars — cosmetic, not failures.
  • There is no CI workflow (adding one was optional per the task and not included).

Link to Devin session: https://app.devin.ai/sessions/267a079877f94aa19879f0ceb6c2f2c8
Requested by: @vibhaseshadri-cognition


Devin Review

Status Commit
⚪ Not started

Run Devin Review

Open in Devin Review (Staging)

Co-Authored-By: Vibha  Seshadri <vibha.seshadri@cognition.ai>
@devin-ai-integration

Copy link
Copy Markdown
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, CI, and merge conflict 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.

0 participants