Cactus
  1. Cactus
  2. CACTUS-219

the cactus scanner return a java.lang.NullPointerException with maven 1.1-beta-1

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.7
    • Fix Version/s: 1.7.1
    • Component/s: Ant Integration
    • Labels:
      None

      Description

      When running the cactus:test-war goal with maven 1.1-beta-1 I get the following stack trace:

      Root cause
      java.lang.NullPointerException
      at org.apache.cactus.integration.maven.CactusScanner.processFileSet(CactusScanner.java:106)
      at org.apache.cactus.integration.maven.CactusScannerTag.doTag(CactusScannerTag.java:123)
      at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:247)
      at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
      at org.apache.maven.jelly.tags.werkz.MavenGoalTag.runBodyTag(MavenGoalTag.java:78)
      at org.apache.maven.jelly.tags.werkz.MavenGoalTag$MavenGoalAction.performAction(MavenGoalTag.java:109)
      at org.apache.maven.werkz.Goal.fire(Goal.java:656)
      at org.apache.maven.werkz.Goal.attain(Goal.java:592)
      at org.apache.maven.werkz.WerkzProject.attainGoal(WerkzProject.java:210)
      at org.apache.maven.jelly.tags.werkz.MavenAttainGoalTag.doTag(MavenAttainGoalTag.java:114)
      at org.apache.commons.jelly.impl.TagScript.run(TagScript.java:247)
      at org.apache.commons.jelly.impl.ScriptBlock.run(ScriptBlock.java:95)
      at org.apache.commons.jelly.TagSupport.invokeBody(TagSupport.java:186)

      This seems to be caused by a change to the class org.apache.tools.ant.types.AbstractFileSet in ant 1.6.x. This class now has a new toString() method which throws the following exception

      Caused by: No directory specified for FileSet.
      at org.apache.tools.ant.types.AbstractFileSet.getDirectoryScanner(AbstractFileSet.java:345)
      at org.apache.tools.ant.types.AbstractFileSet.toString(AbstractFileSet.java:654)
      at java.lang.String.valueOf(String.java:2577)
      at java.lang.StringBuilder.append(StringBuilder.java:116)
      at org.apache.cactus.integration.maven.CactusScannerTag.addFileset(CactusScannerTag.java:173)

      A potential patch to CactusScannerTag.java is attached

      1. CACTUS-219.zip
        2 kB
        Eric Lapierre
      2. CactusScannerTag.patch.zip
        0.5 kB
        Eric Lapierre

        Activity

        No work has yet been logged on this issue.

          People

          • Assignee:
            Felipe Leme
            Reporter:
            Eric Lapierre
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development