Uploaded image for project: 'Thorntail'
  1. Thorntail
  2. THORN-24

error packaging project: java.lang.NoClassDefFoundError: org/eclipse/aether/RepositorySystemSession

    Details

    • Type: Story
    • Status: Closed (View Workflow)
    • Resolution: Done
    • Affects Version/s: None
    • Fix Version/s: 1.0.0.Alpha6
    • Component/s: None
    • Labels:
      None

      Description

      I create a simple JAX-RS application.

      When I try to package the application (mvn clean package) an exception raised and i'm a bit lost:

      [INFO] --- wildfly-swarm-plugin:1.0.0.Alpha1:create (default) @ swarm ---
      may 07, 2015 2:44:38 PM org.sonatype.guice.bean.reflect.Logs$JULSink warn
      ADVERTENCIA: Error injecting: org.wildfly.swarm.plugin.CreateMojo
      java.lang.NoClassDefFoundError: org/eclipse/aether/RepositorySystemSession
      	at java.lang.Class.getDeclaredConstructors0(Native Method)
      	at java.lang.Class.privateGetDeclaredConstructors(Class.java:2671)
      	at java.lang.Class.getDeclaredConstructors(Class.java:2020)
      	at com.google.inject.spi.InjectionPoint.forConstructorOf(InjectionPoint.java:245)
      	at com.google.inject.internal.ConstructorBindingImpl.create(ConstructorBindingImpl.java:99)
      	at com.google.inject.internal.InjectorImpl.createUninitializedBinding(InjectorImpl.java:657)
      	at com.google.inject.internal.InjectorImpl.createJustInTimeBinding(InjectorImpl.java:875)
      	at com.google.inject.internal.InjectorImpl.createJustInTimeBindingRecursive(InjectorImpl.java:798)
      	at com.google.inject.internal.InjectorImpl.getJustInTimeBinding(InjectorImpl.java:281)
      	at com.google.inject.internal.InjectorImpl.getBindingOrThrow(InjectorImpl.java:213)
      	at com.google.inject.internal.InjectorImpl.getProviderOrThrow(InjectorImpl.java:998)
      	at com.google.inject.internal.InjectorImpl.getProvider(InjectorImpl.java:1031)
      	at com.google.inject.internal.InjectorImpl.getProvider(InjectorImpl.java:994)
      	at com.google.inject.internal.InjectorImpl.getInstance(InjectorImpl.java:1044)
      	at org.sonatype.guice.bean.reflect.AbstractDeferredClass.get(AbstractDeferredClass.java:45)
      	at com.google.inject.internal.ProviderInternalFactory.provision(ProviderInternalFactory.java:86)
      	at com.google.inject.internal.InternalFactoryToInitializableAdapter.provision(InternalFactoryToInitializableAdapter.java:54)
      	at com.google.inject.internal.ProviderInternalFactory$1.call(ProviderInternalFactory.java:70)
      	at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:113)
      	at org.sonatype.guice.plexus.lifecycles.PlexusLifecycleManager.onProvision(PlexusLifecycleManager.java:138)
      	at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:122)
      	at com.google.inject.internal.ProvisionListenerStackCallback.provision(ProvisionListenerStackCallback.java:68)
      	at com.google.inject.internal.ProviderInternalFactory.circularGet(ProviderInternalFactory.java:68)
      	at com.google.inject.internal.InternalFactoryToInitializableAdapter.get(InternalFactoryToInitializableAdapter.java:46)
      	at com.google.inject.internal.InjectorImpl$2$1.call(InjectorImpl.java:1009)
      	at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1059)
      	at com.google.inject.internal.InjectorImpl$2.get(InjectorImpl.java:1005)
      	at com.google.inject.Scopes$1$1.get(Scopes.java:59)
      	at org.sonatype.guice.bean.locators.LazyBeanEntry.getValue(LazyBeanEntry.java:83)
      	at org.sonatype.guice.plexus.locators.LazyPlexusBean.getValue(LazyPlexusBean.java:49)
      	at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:253)
      	at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:245)
      	at org.apache.maven.plugin.internal.DefaultMavenPluginManager.getConfiguredMojo(DefaultMavenPluginManager.java:455)
      	at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:92)
      	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
      	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:62)
      	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.lang.reflect.Method.invoke(Method.java:497)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
      Caused by: java.lang.ClassNotFoundException: org.eclipse.aether.RepositorySystemSession
      	at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(SelfFirstStrategy.java:50)
      	at org.codehaus.plexus.classworlds.realm.ClassRealm.unsynchronizedLoadClass(ClassRealm.java:271)
      	at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:247)
      	at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:239)
      	... 54 more
      

      My POM looks like:

      <?xml version="1.0" encoding="UTF-8"?>
      <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
          <modelVersion>4.0.0</modelVersion>
      
          <groupId>com.josemorenoesteban.lab.wildfly</groupId>
          <artifactId>swarm</artifactId>
          <version>0.1.0-snapshot</version>
          <packaging>jar</packaging>
      
          <name>Wildfly Swarm webapp</name>
          
          <properties>
              <maven.compiler.source>1.8</maven.compiler.source>
              <maven.compiler.target>1.8</maven.compiler.target>
              <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
              <version.wildfly-swarm>1.0.0.Alpha1</version.wildfly-swarm>
          </properties>
          
          <dependencies>
              <dependency>
                  <groupId>org.wildfly.swarm</groupId>
                  <artifactId>wildfly-swarm-jaxrs</artifactId>
                  <version>${version.wildfly-swarm}</version>
                  <scope>provided</scope>
              </dependency>
          </dependencies>
      
          <build>
              <plugins>
                  <plugin>
                      <groupId>org.wildfly.swarm</groupId>
                      <artifactId>wildfly-swarm-plugin</artifactId>
                      <version>${version.wildfly-swarm}</version>
                      <executions>
                          <execution>
                              <phase>package</phase>
                              <goals>
                                  <goal>create</goal>
                              </goals>
                          </execution>
                      </executions>
                  </plugin>
              </plugins>
          </build>
      </project>
      

      Environment:

      • ubuntu 15.04 (3.19.0-16-generic)
      • java version: 1.8.0_45
      • maven version: 3.0.5

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                jomoespe Jose Jose (Inactive)
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: