Mojo's Wagon Maven Plugin
  1. Mojo's Wagon Maven Plugin
  2. MWAGON-16

Maven3: java.lang.ClassNotFoundException: org.apache.commons.io.IOUtils

    Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Labels:
      None
    • Environment:
    • Number of attachments :
      0

      Description

      Executing:

      mvn -e org.codehaus.mojo:wagon-maven-plugin:1.0-beta-3:list -Dwagon.url=http://people.apache.org/~olamy/staging-repo/
      

      or:

      mvn -e org.codehaus.mojo:wagon-maven-plugin:1.0-beta-4:list -Dwagon.url=http://people.apache.org/~olamy/staging-repo/
      

      leads to:

      [INFO] Error stacktraces are turned on.
      [INFO] Scanning for projects...
      [INFO]                                                                         
      [INFO] ------------------------------------------------------------------------
      [INFO] Building Maven Stub Project (No POM) 1
      [INFO] ------------------------------------------------------------------------
      [INFO] 
      [INFO] --- wagon-maven-plugin:1.0-beta-4:list (default-cli) @ standalone-pom ---
      [INFO] Scanning remote file system: http://people.apache.org/~olamy/staging-repo/ ...
      [INFO] ------------------------------------------------------------------------
      [INFO] BUILD FAILURE
      [INFO] ------------------------------------------------------------------------
      [INFO] Total time: 1.576s
      [INFO] Finished at: Tue Apr 10 21:09:39 CEST 2012
      [INFO] Final Memory: 5M/81M
      [INFO] ------------------------------------------------------------------------
      [ERROR] Failed to execute goal org.codehaus.mojo:wagon-maven-plugin:1.0-beta-4:list (default-cli) on project standalone-pom: Execution default-cli of goal org.codehaus.mojo:wagon-maven-plugin:1.0-beta-4:list failed: A required class was missing while executing org.codehaus.mojo:wagon-maven-plugin:1.0-beta-4:list: org/apache/commons/io/IOUtils
      [ERROR] -----------------------------------------------------
      [ERROR] realm =    plugin>org.codehaus.mojo:wagon-maven-plugin:1.0-beta-4
      [ERROR] strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
      [ERROR] urls[0] = file:/Software/nobackup/m2repo/org/codehaus/mojo/wagon-maven-plugin/1.0-beta-4/wagon-maven-plugin-1.0-beta-4.jar
      [ERROR] urls[1] = file:/Software/nobackup/m2repo/org/codehaus/plexus/plexus-utils/1.5.6/plexus-utils-1.5.6.jar
      [ERROR] urls[2] = file:/Software/nobackup/m2repo/org/apache/maven/shared/file-management/1.2.1/file-management-1.2.1.jar
      [ERROR] urls[3] = file:/Software/nobackup/m2repo/org/apache/maven/shared/maven-shared-io/1.1/maven-shared-io-1.1.jar
      [ERROR] Number of foreign imports: 1
      [ERROR] import: Entry[import  from realm ClassRealm[maven.api, parent: null]]
      [ERROR] 
      [ERROR] -----------------------------------------------------: org.apache.commons.io.IOUtils
      [ERROR] -> [Help 1]
      org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.codehaus.mojo:wagon-maven-plugin:1.0-beta-4:list (default-cli) on project standalone-pom: Execution default-cli of goal org.codehaus.mojo:wagon-maven-plugin:1.0-beta-4:list failed: A required class was missing while executing org.codehaus.mojo:wagon-maven-plugin:1.0-beta-4:list: org/apache/commons/io/IOUtils
      -----------------------------------------------------
      realm =    plugin>org.codehaus.mojo:wagon-maven-plugin:1.0-beta-4
      strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
      urls[0] = file:/Software/nobackup/m2repo/org/codehaus/mojo/wagon-maven-plugin/1.0-beta-4/wagon-maven-plugin-1.0-beta-4.jar
      urls[1] = file:/Software/nobackup/m2repo/org/codehaus/plexus/plexus-utils/1.5.6/plexus-utils-1.5.6.jar
      urls[2] = file:/Software/nobackup/m2repo/org/apache/maven/shared/file-management/1.2.1/file-management-1.2.1.jar
      urls[3] = file:/Software/nobackup/m2repo/org/apache/maven/shared/maven-shared-io/1.1/maven-shared-io-1.1.jar
      Number of foreign imports: 1
      import: Entry[import  from realm ClassRealm[maven.api, parent: null]]
      
      -----------------------------------------------------
      
      	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:225)
      	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
      	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
      	at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
      	at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
      	at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
      	at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
      	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320)
      	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
      	at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537)
      	at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)
      	at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)
      	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.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
      Caused by: org.apache.maven.plugin.PluginExecutionException: Execution default-cli of goal org.codehaus.mojo:wagon-maven-plugin:1.0-beta-4:list failed: A required class was missing while executing org.codehaus.mojo:wagon-maven-plugin:1.0-beta-4:list: org/apache/commons/io/IOUtils
      -----------------------------------------------------
      realm =    plugin>org.codehaus.mojo:wagon-maven-plugin:1.0-beta-4
      strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
      urls[0] = file:/Software/nobackup/m2repo/org/codehaus/mojo/wagon-maven-plugin/1.0-beta-4/wagon-maven-plugin-1.0-beta-4.jar
      urls[1] = file:/Software/nobackup/m2repo/org/codehaus/plexus/plexus-utils/1.5.6/plexus-utils-1.5.6.jar
      urls[2] = file:/Software/nobackup/m2repo/org/apache/maven/shared/file-management/1.2.1/file-management-1.2.1.jar
      urls[3] = file:/Software/nobackup/m2repo/org/apache/maven/shared/maven-shared-io/1.1/maven-shared-io-1.1.jar
      Number of foreign imports: 1
      import: Entry[import  from realm ClassRealm[maven.api, parent: null]]
      
      -----------------------------------------------------
      
      	at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:127)
      	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
      	... 19 more
      Caused by: org.apache.maven.plugin.PluginContainerException: A required class was missing while executing org.codehaus.mojo:wagon-maven-plugin:1.0-beta-4:list: org/apache/commons/io/IOUtils
      -----------------------------------------------------
      realm =    plugin>org.codehaus.mojo:wagon-maven-plugin:1.0-beta-4
      strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
      urls[0] = file:/Software/nobackup/m2repo/org/codehaus/mojo/wagon-maven-plugin/1.0-beta-4/wagon-maven-plugin-1.0-beta-4.jar
      urls[1] = file:/Software/nobackup/m2repo/org/codehaus/plexus/plexus-utils/1.5.6/plexus-utils-1.5.6.jar
      urls[2] = file:/Software/nobackup/m2repo/org/apache/maven/shared/file-management/1.2.1/file-management-1.2.1.jar
      urls[3] = file:/Software/nobackup/m2repo/org/apache/maven/shared/maven-shared-io/1.1/maven-shared-io-1.1.jar
      Number of foreign imports: 1
      import: Entry[import  from realm ClassRealm[maven.api, parent: null]]
      
      -----------------------------------------------------
      
      	at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:125)
      	... 20 more
      Caused by: java.lang.NoClassDefFoundError: org/apache/commons/io/IOUtils
      	at org.apache.maven.wagon.shared.http4.HtmlFileListParser.parseFileList(HtmlFileListParser.java:77)
      	at org.apache.maven.wagon.providers.http.HttpWagon.getFileList(HttpWagon.java:92)
      	at org.codehaus.mojo.wagon.shared.WagonDirectoryScanner.scandir(WagonDirectoryScanner.java:306)
      	at org.codehaus.mojo.wagon.shared.WagonDirectoryScanner.scan(WagonDirectoryScanner.java:250)
      	at org.codehaus.mojo.wagon.shared.DefaultWagonDownload.getFileList(DefaultWagonDownload.java:52)
      	at org.codehaus.mojo.wagon.ListMojo.execute(ListMojo.java:38)
      	at org.codehaus.mojo.wagon.AbstractSingleWagonMojo.execute(AbstractSingleWagonMojo.java:63)
      	at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)
      	... 20 more
      Caused by: java.lang.ClassNotFoundException: org.apache.commons.io.IOUtils
      	at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(SelfFirstStrategy.java:50)
      	at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:244)
      	at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:230)
      	... 28 more
      [ERROR] 
      [ERROR] Re-run Maven using the -X switch to enable full debug logging.
      [ERROR] 
      [ERROR] For more information about the errors and possible solutions, please read the following articles:
      [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginContainerException
      

        Issue Links

          Activity

          Hide
          Alexander Goehring added a comment -

          MOJO-1832 is a duplicate of MOJO-1821

          Show
          Alexander Goehring added a comment - MOJO-1832 is a duplicate of MOJO-1821
          Hide
          Ernst de Haan added a comment - - edited

          The same issues applies to the Stage plugin, see MSTAGE-16.

          It might be possible to add some class path entry/ies to the plugin on execution to work around this?

          Show
          Ernst de Haan added a comment - - edited The same issues applies to the Stage plugin, see MSTAGE-16 . It might be possible to add some class path entry/ies to the plugin on execution to work around this?
          Hide
          Dan Tran added a comment -

          fixed at

          Revision: 19410
          Author: dantran
          Date: Thursday, February 13, 2014 6:40:51 PM
          Message:
          MOJO-1832 work around for WAGON-407


          Modified : /trunk/mojo/wagon-maven-plugin/pom.xml
          Added : /trunk/mojo/wagon-maven-plugin/src/main/java/org/codehaus/mojo/wagon/UpdateMaven3Mojo.java
          Modified : /trunk/mojo/wagon-maven-plugin/src/site/apt/usage.apt

          Show
          Dan Tran added a comment - fixed at Revision: 19410 Author: dantran Date: Thursday, February 13, 2014 6:40:51 PM Message: MOJO-1832 work around for WAGON-407 Modified : /trunk/mojo/wagon-maven-plugin/pom.xml Added : /trunk/mojo/wagon-maven-plugin/src/main/java/org/codehaus/mojo/wagon/UpdateMaven3Mojo.java Modified : /trunk/mojo/wagon-maven-plugin/src/site/apt/usage.apt

            People

            • Assignee:
              Dan Tran
              Reporter:
              Mirko Friedenhagen
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: