-
Notifications
You must be signed in to change notification settings - Fork 0
Update build to Java 21 #1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
The head ref may contain hidden characters: "codex/mettre-\u00E0-jour-le-repo-en-java-21"
Conversation
WalkthroughThe project was updated to require Java 21, with this requirement documented in the README and the Kotlin Maven plugin's JVM target set to 21 in the build configuration. No changes were made to public APIs or exported entities. Changes
Poem
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (1)
README.md (1)
5-8: Use consistent formatting and terminology for requirements
Rather than**Java 21**with an HTML entity, consider inline code for clarity and accuracy. For example:## Requirements Ensure you have **JDK 21** installed to compile and run the solutions.This improves readability and clearly signals an environment prerequisite.
| <configuration> | ||
| <jvmTarget>1.8</jvmTarget> | ||
| <jvmTarget>21</jvmTarget> | ||
| </configuration> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🛠️ Refactor suggestion
Ensure Kotlin compilation target is applied in each execution
The global <jvmTarget>21</jvmTarget> sits outside your <execution> blocks, but executions with their own <configuration> (e.g., compile) may override or ignore it. To guarantee both compile and test-compile use JVM 21, move the jvmTarget setting into each execution’s <configuration>.
Proposed diff:
<execution>
<id>compile</id>
<phase>process-sources</phase>
<goals>
<goal>compile</goal>
</goals>
- <configuration>
- <sourceDirs>
- <source>src/main/java</source>
- <source>target/generated-sources/annotations</source>
- </sourceDirs>
- </configuration>
+ <configuration>
+ <sourceDirs>
+ <source>src/main/java</source>
+ <source>target/generated-sources/annotations</source>
+ </sourceDirs>
+ <jvmTarget>21</jvmTarget>
+ </configuration>
</execution>
<execution>
<id>test-compile</id>
<phase>test-compile</phase>
<goals>
<goal>test-compile</goal>
</goals>
+ <configuration>
+ <jvmTarget>21</jvmTarget>
+ </configuration>
</execution>📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| <configuration> | |
| <jvmTarget>1.8</jvmTarget> | |
| <jvmTarget>21</jvmTarget> | |
| </configuration> | |
| <execution> | |
| <id>compile</id> | |
| <phase>process-sources</phase> | |
| <goals> | |
| <goal>compile</goal> | |
| </goals> | |
| <configuration> | |
| <sourceDirs> | |
| <source>src/main/java</source> | |
| <source>target/generated-sources/annotations</source> | |
| </sourceDirs> | |
| <jvmTarget>21</jvmTarget> | |
| </configuration> | |
| </execution> | |
| <execution> | |
| <id>test-compile</id> | |
| <phase>test-compile</phase> | |
| <goals> | |
| <goal>test-compile</goal> | |
| </goals> | |
| <configuration> | |
| <jvmTarget>21</jvmTarget> | |
| </configuration> | |
| </execution> |
🤖 Prompt for AI Agents
In pom.xml around lines 39 to 41, the <jvmTarget>21</jvmTarget> setting is
placed globally but not inside each <execution> block, which can cause
executions like compile and test-compile to override or ignore it. To fix this,
move the <jvmTarget>21</jvmTarget> configuration into the <configuration>
section of each <execution> block to ensure all executions consistently use JVM
target 21.
Summary
jvmTargetto 21Testing
mvn -q test(fails: Plugin could not be resolved)https://chatgpt.com/codex/tasks/task_e_6841ba81e67c83269197775fb71f6d42
Summary by CodeRabbit
Documentation
Chores