"mvn site" fails on dependency management information when using EAP 6 BOMs
Issue
- Running 'mvn site' under java 1.7 fails in DependencyManagement section due to a reference to tools.jar hard-wired to java 1.6. Due to this problem, our CI server claims the build has failed. However, its only the DependencyManagement analysis that is failing, wrongly, a false negative. My only workaround now is to disable DependencyManagement analysis.
[INFO] Generating "Dependency Management" report --- maven-project-info-reports-plugin:2.8
[WARNING] Unable to create Maven project for com.sun:tools:pom:1.6 from repository.
org.apache.maven.project.ProjectBuildingException: Error resolving project artifact: Failure to find com.sun:tools:pom:1.6 in https://*******.
This are the artifact that reference tools.jar:
<groupId>org.jboss</groupId>
<version>11-redhat-1</version>
<artifactId>jboss-parent</artifactId>
This is the segment in that file. The above failure does not occur when I comment these lines out.
<dependencyManagement>
<dependencies>
<dependency>
<groupId>com.sun</groupId>
<artifactId>tools</artifactId>
<scope>system</scope>
<version>1.6</version>
<systemPath>${com.sun.tools.path}</systemPath>
</dependency>
</dependencies>
</dependencyManagement>
Changing JAVA_HOME to the 1.7 JRE or JDK does not resolve.
Neither does: mvn site -Djava-home=/path to java 1.7
Environment
- Red Hat JBoss Enterprise Application Platform (EAP)
- 6.x
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.