Maven Linkcheck Plugin
  1. Maven Linkcheck Plugin
  2. MLINKCHECK-4

Add support for wildcards in excludedPages

    Details

    • Type: Improvement Improvement
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.0.1
    • Fix Version/s: 1.1
    • Labels:
      None
    • Number of attachments :
      0

      Description

      It would be great to get support for wildcards in excludedPages. Currently I get a whole lot of false positives from my javadocs and xref documentation. It would be very nice if I could just exclude these pages from being checked using something like:

      <excludedPages>
      <excludedPage>xref-test/**</excludedPage>
      <excludedPage>apidocs/**</excludedPage>
      </excludedPages>

      Excluded link doesn't really work in this case because most of the links in the javadocs are relative to apidocs. So there is no obvious pattern that can be used here.

      Also the javadocs produce URIs that cannot be parsed by java.net.URI giving errors like the following:

      [INFO] ------------------------------------------------------------------------
      [ERROR] FATAL ERROR
      [INFO] ------------------------------------------------------------------------
      [INFO] null
      Illegal character in fragment at index 98: ./org/lds/stack/db/listener/ConnectionListenerDataSourceP
      roxy.html#getConnection(java.lang.String, java.lang.String)
      [INFO] ------------------------------------------------------------------------
      [INFO] Trace
      java.lang.IllegalArgumentException
      at java.net.URI.create(URI.java:842)
      at org.apache.maven.doxia.linkcheck.validation.LinkValidatorManager.matchPattern(LinkValidat
      orManager.java:414)
      at org.apache.maven.doxia.linkcheck.validation.LinkValidatorManager.validateLink(LinkValidat
      orManager.java:132)
      at org.apache.maven.doxia.linkcheck.DefaultLinkCheck.check(DefaultLinkCheck.java:558)
      at org.apache.maven.doxia.linkcheck.DefaultLinkCheck.findAndCheckFiles(DefaultLinkCheck.java
      :480)
      at org.apache.maven.doxia.linkcheck.DefaultLinkCheck.findAndCheckFiles(DefaultLinkCheck.java
      :439)
      at org.apache.maven.doxia.linkcheck.DefaultLinkCheck.execute(DefaultLinkCheck.java:241)
      at org.apache.maven.plugins.linkcheck.LinkcheckReport.executeLinkCheck(LinkcheckReport.java:
      512)
      at org.apache.maven.plugins.linkcheck.LinkcheckReport.execute(LinkcheckReport.java:412)
      at org.apache.maven.plugins.linkcheck.LinkcheckReport.executeReport(LinkcheckReport.java:452
      )
      at org.apache.maven.reporting.AbstractMavenReport.generate(AbstractMavenReport.java:93)
      at org.apache.maven.plugins.site.ReportDocumentRenderer.renderDocument(ReportDocumentRendere
      r.java:164)
      at org.apache.maven.doxia.siterenderer.DefaultSiteRenderer.renderModule(DefaultSiteRenderer.
      java:330)
      at org.apache.maven.doxia.siterenderer.DefaultSiteRenderer.render(DefaultSiteRenderer.java:1
      34)
      at org.apache.maven.plugins.site.SiteMojo.renderLocale(SiteMojo.java:158)
      at org.apache.maven.plugins.site.SiteMojo.execute(SiteMojo.java:120)
      at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
      at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor
      .java:694)
      at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifec
      ycleExecutor.java:556)
      at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.
      java:535)
      at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultL
      ifecycleExecutor.java:387)
      at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleE
      xecutor.java:348)
      at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java
      :180)
      at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
      at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
      at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
      at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      at java.lang.reflect.Method.invoke(Method.java:597)
      at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
      at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
      at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
      at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
      Caused by: java.net.URISyntaxException: Illegal character in fragment at index 98: ./org/lds/stack/d
      b/listener/ConnectionListenerDataSourceProxy.html#getConnection(java.lang.String, java.lang.String)
      at java.net.URI$Parser.fail(URI.java:2809)
      at java.net.URI$Parser.checkChars(URI.java:2982)
      at java.net.URI$Parser.parse(URI.java:3028)
      at java.net.URI.<init>(URI.java:578)
      at java.net.URI.create(URI.java:840)
      ... 34 more

        Issue Links

          Activity

          Hide
          Lukas Theussl added a comment -

          Fixed with DOXIA-412, snapshot is deployed, please test.

          For the error, please file it as a separate issue with a concrete example.

          Show
          Lukas Theussl added a comment - Fixed with DOXIA-412 , snapshot is deployed, please test. For the error, please file it as a separate issue with a concrete example.
          Hide
          Lukas Theussl added a comment -
          Show
          Lukas Theussl added a comment - See MLINKCHECK-6 .

            People

            • Assignee:
              Lukas Theussl
              Reporter:
              Mike Youngstrom
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: