ERROR - Maven - JavaDoc Errors while using Java 8

Problem


JavaDoc Errors while using Java 8

Cause

Java 8 uses DocLint which is a new feature introduced to detect Javadoc comments errors.

Resolution

Either you can fix those errors or Ignore them. 

To ignore, add the following code to the Pom file within plugins tags -

<plugin>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-javadoc-plugin</artifactId>
    <version>2.9</version>
    <executions>
        <execution>
            <id>attach-javadocs</id>
            <goals>
                <goal>jar</goal>
            </goals>
            <configuration>
                <additionalparam>-Xdoclint:none</additionalparam>
            </configuration>
        </execution>
     </executions>

</plugin>

or add following within properties tags -

<additionalparam>-Xdoclint:none</additionalparam>


** This feature will give Warnings instead of errors with Java 9. Objective is to allow the build to complete successfully even if doclint hasn't been ignored within pom file. JEP - http://openjdk.java.net/jeps/212