[
https://issues.apache.org/jira/browse/HADOOP-19779?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18051063#comment-18051063
]
ASF GitHub Bot commented on HADOOP-19779:
-----------------------------------------
edwardcapriolo commented on PR #8173:
URL: https://github.com/apache/hadoop/pull/8173#issuecomment-3733929940
Thanks for doing this. Have you also considered this approach:
https://github.com/edwardcapriolo/deliverance/blob/6d7cae5463be598b7365e45a6d2773b3b2bece41/pom.xml#L103
```xml
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<release>25</release>
<jdkToolchain><version>25</version></jdkToolchain>
</configuration>
</plugin>
```
> Use enforcer to fail fast if building with Java <17
> ---------------------------------------------------
>
> Key: HADOOP-19779
> URL: https://issues.apache.org/jira/browse/HADOOP-19779
> Project: Hadoop Common
> Issue Type: Improvement
> Components: build
> Reporter: Chris Nauroth
> Assignee: Chris Nauroth
> Priority: Major
> Labels: pull-request-available
>
> Now that trunk has gone to Java 17, we've had some reports of confusion when
> accidentally building with a down-level Java. It goes into the
> hadoop-annotations build and reports the --add-modules compiler option isn't
> recognized, but it doesn't do anything to indicate that root cause is the
> Java version. We can improve on this by updating our enforcer plugin rules to
> check for Java 17+ and fail with an error message clearly pointing out the
> Java version.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]