Uploaded image for project: 'Maven Javadoc Plugin'
  1. Maven Javadoc Plugin
  2. MJAVADOC-494

javadoc:aggregate ignores repositories declared in sub-modules

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.0.0-M1
    • 3.0.0
    • javadoc
    • Maven Javadoc plugin 3.0.0-M1
      Apache Maven 3.5.0
      Java version 1.8.0_144

    Description

      Given a multi-modules project with:

      • A <repository>… URL A …</repository> element in the root pom.xml.
      • Another <repository>… URL B …</repository> element in the pom.xml of a module, for downloading a JAR file used only by that specific module (we do that in order to depend only on Maven central for all modules except one).

      Then:

      • mvn install works: it download all JAR files as expected.
      • mvn javadoc:javadoc also work with both Maven Javadoc plugin 2.10.4 and 3.0.0-M1.
      • mvn javadoc:aggregate with Maven Javadoc plugin 2.10.4 works.
      • mvn javadoc:aggregate with Maven Javadoc plugin 3.0.0-M1 fails.

      Maven Javadoc plugin 3.0.0-M1 execution produces the following logs (simplified for brevity):

      Downloading: URL A/.../MyArtifact.jar
      Downloading: https://repo.maven.apache.org/maven2/.../MyArtifact.jar
      

      No download attempt from URL B is reported, despite the <repository> declaration in a sub-module. Note that the JAR is present in my .m2/repository directory but is apparently ignored.

      Downgrading Maven Javadoc plugin to 2.10.4 with everything else identical allows successful aggregated Javadoc generation.

      Note: another user apparently has the same issue on stack overflow.

      Attachments

        Activity

          People

            rfscholte Robert Scholte
            desruisseaux Martin Desruisseaux
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: