maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robert Scholte (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (MJAVADOC-523) Exclude non-Java JARs from Maven Javadoc plugin processing
Date Sat, 01 Dec 2018 19:29:00 GMT

    [ https://issues.apache.org/jira/browse/MJAVADOC-523?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16705968#comment-16705968
] 

Robert Scholte commented on MJAVADOC-523:
-----------------------------------------

Please provide a project to reproduce

> Exclude non-Java JARs from Maven Javadoc plugin processing
> ----------------------------------------------------------
>
>                 Key: MJAVADOC-523
>                 URL: https://issues.apache.org/jira/browse/MJAVADOC-523
>             Project: Maven Javadoc Plugin
>          Issue Type: Bug
>          Components: javadoc
>    Affects Versions: 2.8
>            Reporter: Thorsten Glaser
>            Assignee: Robert Scholte
>            Priority: Minor
>
> I have a multi-module project which builds a couple of JARs and then distributed them
into two WARs.
> However, one of the JARs does not contain any Java code at all, merely (maven-filtered)
resources. This leads to warnings during the build like these: 
> {noformat}[…]
>  [INFO] — maven-javadoc-plugin:2.8:jar (attach-javadocs) @ foo-services —
>  [INFO] The goal 'org.apache.maven.plugins:maven-javadoc-plugin:2.8:javadoc' has not
been previously called for the module: 'de.tarent.foo:foo-rsrcs:jar:1.3.900-SNAPSHOT'. Trying
to invoke it...
> [WARNING] Creating fake javadoc directory to prevent repeated invocations: /var/lib/jenkins/jobs/FooTool/workspace/foo-backend/foo-rsrcs/target/apidocs
>  [ERROR] Error fetching link: /var/lib/jenkins/jobs/FooTool/workspace/foo-backend/foo-rsrcs/target/apidocs/package-list.
Ignored it.
> [INFO] 
>  Loading source files for package de.tarent.foo.rest.transformation...
>  […]{noformat}
>  I found how I can exclude javadoc stuff by package, but not by artifact.
> The plugin is currently included ONLY in the parent POM, like this:
> {code:xml} 
> <plugin>
>   <groupId>org.apache.maven.plugins</groupId>
>   <artifactId>maven-javadoc-plugin</artifactId>
>   <version>2.8</version>
>   <executions>
>     <execution>
>       <id>attach-javadocs</id>
>       <goals>
>         <goal>jar</goal>
>       </goals>
>     </execution>
>   </executions>
> </plugin>
> {code}
>  While it _is_ run during “compilation” of the resources-only JAR, it (obviously)
produces no result, thus the warning (as it’s not excluded either).
> How can I either make it produce something (i.e. the ability to create a valid-looking
yet contentless FOO-javadoc.jar that satisfies references by reverse dependencies, in a JAR
not containing any Java™ code) or, probably preferably, exclude the {{foo-rsrcs}} module
from being accessed by mjavadoc on modules depending on it?



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message