Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [] targeting JDK 8 *and* JDK 11?

On 9/23/19 9:02 PM, Bill Shannon wrote:
Are you just generating the javadocs separately, without using Maven?

no, maven does that as part of the build

How does the javadoc jar file get generated when you do "mvn deploy"?

'mvn deploy' only builds and deploys main project artifact, it does not care about javadoc nor sources in my case. To have also javadoc and source bundles created 'mvn deploy -Poss-release' must be used (project defines configuration for javadoc and source plugins and oss-release profile inherited from parent pom defines their execution). Most projects should already have their jobs set up for release as well as for snapshot build like ie jws-api, see for exact setup for jws-api master build/jws-api release jobs @

The former is useful for developers to have faster build, the latter for build jobs where build time does not matter that much. If developer needs javadoc and/or source bundles, then (s)he must explicitly turn on oss-profile and either configure gpg on her/his end or pass '-Dgpg.skip=true' to maven together with '-Poss-release'.


[ERROR] Failed to execute goal
org.apache.maven.plugins:maven-javadoc-plugin:3.1.1:javadoc (default-cli) on
project jakarta.xml.bind-api: An error has occurred in Javadoc report generation:
[ERROR] Exit code: 1 - error: module not found: java.xml.bind

I played around with the javadoc tool by hand, using the options the
maven-javadoc-plugin generates, and I can't figure out how to generate
the javadocs for a module.  Have you made this work?

yes, I made that work - removing lines related to '--patch-module' and
'--module-source-path' options and explicitly adding '--source-path' pointing to
the main source roots (src/main/java etc) helped

Yes, I can run javadoc by hand if I ignore the module options.

Have you made Maven run javadoc this way?

Back to the top