Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Blocker Blocker
    • Resolution: Fixed
    • Affects Version/s: 2.6.1
    • Fix Version/s: 2.8
    • Labels:
      None
    • Environment:
    • Flags:
      Patch

      Description

      When setting 'detectLinks' to 'true', the plugin checks that access to the constructed package-list files is possible by checking the HTTP status code to match 200. This check should be more strict and additionally check that the accessed package-list file is of correct type. For example, if setting detect links to 'true' and having a dependency on 'javax.annotation:jsr250-api' the plugin will add a link like 'http://jcp.org/aboutJava/communityprocess/final/jsr250/index.html/apidocs' so that javadoc will then try to access the package-list file located at 'http://jcp.org/aboutJava/communityprocess/final/jsr250/index.html/apidocs/package-list'. That link returns a HTTP status code 200 but no valid package-list file. Using the following javadoc plugin configuration

              <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>2.7</version>
                <configuration>
                  <breakiterator>true</breakiterator>
                  <keywords>true</keywords>
                  <linksource>true</linksource>
                  <serialwarn>true</serialwarn>
                  <source>1.5</source>
                  <doctitle>${project.name} ${project.version}</doctitle>
                  <windowtitle>${project.name} ${project.version}</windowtitle>
                  <detectJavaApiLink>true</detectJavaApiLink>
                  <detectOfflineLinks>false</detectOfflineLinks>
                  <detectLinks>true</detectLinks>
                  <doclet>org.umlgraph.doclet.UmlGraphDoc</doclet>
                  <docletArtifact>
                    <groupId>org.umlgraph</groupId>
                    <artifactId>doclet</artifactId>
                    <version>5.1</version>
                  </docletArtifact>
                  <tagletArtifacts>
                    <tagletArtifact>
                      <groupId>org.apache.maven.plugin-tools</groupId>
                      <artifactId>maven-plugin-tools-javadoc</artifactId>
                      <version>2.5</version>
                    </tagletArtifact>
                    <tagletArtifact>
                      <groupId>org.codehaus.plexus</groupId>
                      <artifactId>plexus-javadoc</artifactId>
                      <version>1.0</version>
                    </tagletArtifact>
                  </tagletArtifacts>
                  <additionalparam>
                    -inferrel -inferdep -hide java.* -collpackages java.util.* -qualify -postfixpackage -nodefontsize 9
                    -nodefontpackagesize 7
                  </additionalparam>
                  <archive>
                    <index>true</index>
                    <addMavenDescriptor>false</addMavenDescriptor>
                    <compress>true</compress>
                  </archive>
                </configuration>
              </plugin>
      

      the configured umlgraph doclet will fail when trying to parse the retrieved HTML document as a package-list file.

        Issue Links

          Activity

          Mark Thomas made changes -
          Workflow jira [ 12960176 ] Default workflow, editable Closed status [ 12997055 ]
          Mark Thomas made changes -
          Project Import Mon Apr 06 00:11:46 UTC 2015 [ 1428279106587 ]
          Mark Thomas made changes -
          Flags Patch [ 10430 ]
          Patch Submitted Yes [ 10763 ]
          Mark Thomas made changes -
          Workflow jira [ 12722518 ] Default workflow, editable Closed status [ 12762379 ]
          Mark Thomas made changes -
          Project Import Sun Apr 05 11:56:47 UTC 2015 [ 1428235007093 ]
          Hervé Boutemy made changes -
          Link This issue relates to MJAVADOC-354 [ MJAVADOC-354 ]
          Hervé Boutemy made changes -
          Fix Version/s 2.8 [ 16433 ]
          Resolution Fixed [ 1 ]
          Status Open [ 1 ] Closed [ 6 ]
          Assignee Herve Boutemy [ hboutemy ]
          schulte2005 made changes -
          Attachment MJAVADOC-283.patch [ 53145 ]
          Hervé Boutemy made changes -
          Description When setting 'detectLinks' to 'true', the plugin checks that access to the constructed package-list files is possible by checking the HTTP status code to match 200. This check should be more strict and additionally check that the accessed package-list file is of correct type. For example, if setting detect links to 'true' and having a dependency on 'javax.annotation:jsr250-api' the plugin will add a link like 'http://jcp.org/aboutJava/communityprocess/final/jsr250/index.html/apidocs&#39; so that javadoc will then try to access the package-list file located at 'http://jcp.org/aboutJava/communityprocess/final/jsr250/index.html/apidocs/package-list&#39;. That link returns a HTTP status code 200 but no valid package-list file. Using the following javadoc plugin configuration

          {xml}
                  <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <version>2.7</version>
                    <configuration>
                      <breakiterator>true</breakiterator>
                      <keywords>true</keywords>
                      <linksource>true</linksource>
                      <serialwarn>true</serialwarn>
                      <source>1.5</source>
                      <doctitle>${project.name} ${project.version}</doctitle>
                      <windowtitle>${project.name} ${project.version}</windowtitle>
                      <detectJavaApiLink>true</detectJavaApiLink>
                      <detectOfflineLinks>false</detectOfflineLinks>
                      <detectLinks>true</detectLinks>
                      <doclet>org.umlgraph.doclet.UmlGraphDoc</doclet>
                      <docletArtifact>
                        <groupId>org.umlgraph</groupId>
                        <artifactId>doclet</artifactId>
                        <version>5.1</version>
                      </docletArtifact>
                      <tagletArtifacts>
                        <tagletArtifact>
                          <groupId>org.apache.maven.plugin-tools</groupId>
                          <artifactId>maven-plugin-tools-javadoc</artifactId>
                          <version>2.5</version>
                        </tagletArtifact>
                        <tagletArtifact>
                          <groupId>org.codehaus.plexus</groupId>
                          <artifactId>plexus-javadoc</artifactId>
                          <version>1.0</version>
                        </tagletArtifact>
                      </tagletArtifacts>
                      <additionalparam>
                        -inferrel -inferdep -hide java.* -collpackages java.util.* -qualify -postfixpackage -nodefontsize 9
                        -nodefontpackagesize 7
                      </additionalparam>
                      <archive>
                        <index>true</index>
                        <addMavenDescriptor>false</addMavenDescriptor>
                        <compress>true</compress>
                      </archive>
                    </configuration>
                  </plugin>
          {xml}
           
          the configured umlgraph doclet will fail when trying to parse the retrieved HTML document as a package-list file.
          When setting 'detectLinks' to 'true', the plugin checks that access to the constructed package-list files is possible by checking the HTTP status code to match 200. This check should be more strict and additionally check that the accessed package-list file is of correct type. For example, if setting detect links to 'true' and having a dependency on 'javax.annotation:jsr250-api' the plugin will add a link like 'http://jcp.org/aboutJava/communityprocess/final/jsr250/index.html/apidocs&#39; so that javadoc will then try to access the package-list file located at 'http://jcp.org/aboutJava/communityprocess/final/jsr250/index.html/apidocs/package-list&#39;. That link returns a HTTP status code 200 but no valid package-list file. Using the following javadoc plugin configuration

          {code:xml}
                  <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <version>2.7</version>
                    <configuration>
                      <breakiterator>true</breakiterator>
                      <keywords>true</keywords>
                      <linksource>true</linksource>
                      <serialwarn>true</serialwarn>
                      <source>1.5</source>
                      <doctitle>${project.name} ${project.version}</doctitle>
                      <windowtitle>${project.name} ${project.version}</windowtitle>
                      <detectJavaApiLink>true</detectJavaApiLink>
                      <detectOfflineLinks>false</detectOfflineLinks>
                      <detectLinks>true</detectLinks>
                      <doclet>org.umlgraph.doclet.UmlGraphDoc</doclet>
                      <docletArtifact>
                        <groupId>org.umlgraph</groupId>
                        <artifactId>doclet</artifactId>
                        <version>5.1</version>
                      </docletArtifact>
                      <tagletArtifacts>
                        <tagletArtifact>
                          <groupId>org.apache.maven.plugin-tools</groupId>
                          <artifactId>maven-plugin-tools-javadoc</artifactId>
                          <version>2.5</version>
                        </tagletArtifact>
                        <tagletArtifact>
                          <groupId>org.codehaus.plexus</groupId>
                          <artifactId>plexus-javadoc</artifactId>
                          <version>1.0</version>
                        </tagletArtifact>
                      </tagletArtifacts>
                      <additionalparam>
                        -inferrel -inferdep -hide java.* -collpackages java.util.* -qualify -postfixpackage -nodefontsize 9
                        -nodefontpackagesize 7
                      </additionalparam>
                      <archive>
                        <index>true</index>
                        <addMavenDescriptor>false</addMavenDescriptor>
                        <compress>true</compress>
                      </archive>
                    </configuration>
                  </plugin>
          {code}
           
          the configured umlgraph doclet will fail when trying to parse the retrieved HTML document as a package-list file.
          schulte2005 made changes -
          Field Original Value New Value
          Attachment MJAVADOC-283.patch [ 48784 ]
          Christian Schulte created issue -

            People

            • Assignee:
              Hervé Boutemy
              Reporter:
              Christian Schulte
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development