Uploaded image for project: 'Maven'
  1. Maven
  2. MNG-4864

npe when transferring artifacts

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 3.0
    • 3.0.1
    • None
    • None

    Description

      I get the following NPE when running a mvn clean install with an empty local repository. The two stracktraces below show that the build breaks with different artifacts but always at the same place.
      If I relaunch the build several times, it finally succeeds.

      Caused by: java.lang.NullPointerException 
              at org.apache.maven.cli.ConsoleMavenTransferListener.transferProgressed(ConsoleMavenTransferListener.java:60) 
      
      [ERROR] Failed to execute goal on project stdlib-core: Could not resolve dependencies for project com.mycompany:stdlib-core:jar:3.0.0-SNAPSHOT: Could not transfer artifact org.apache.maven:maven-repository-metadata:jar:2.0.8 from nexus (http://maven/nexus/content/groups/public): NullPointerException -> [Help 1] 
      org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal on project stdlib-core: Could not resolve dependencies for project com.mycompany:stdlib-core:jar:3.0.0-SNAPSHOT: Could not transfer artifact org.apache.maven:maven-repository-metadata:jar:2.0.8 from nexus (http://maven/nexus/content/groups/public): NullPointerException 
              at org.apache.maven.lifecycle.internal.LifecycleDependencyResolver.getDependencies(LifecycleDependencyResolver.java:190) 
              at org.apache.maven.lifecycle.internal.LifecycleDependencyResolver.resolveProjectDependencies(LifecycleDependencyResolver.java:104) 
              at org.apache.maven.lifecycle.internal.MojoExecutor.ensureDependenciesAreResolved(MojoExecutor.java:244) 
              at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:187) 
              at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:148) 
              at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:140) 
              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:314) 
              at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:151) 
              at org.apache.maven.cli.MavenCli.execute(MavenCli.java:445) 
              at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:168) 
              at org.apache.maven.cli.MavenCli.main(MavenCli.java:132) 
              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:585) 
              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.project.DependencyResolutionException: Could not resolve dependencies for project com.mycompany:stdlib-core:jar:3.0.0-SNAPSHOT: Could not transfer artifact org.apache.maven:maven-repository-metadata:jar:2.0.8 from nexus (http://maven/nexus/content/groups/public): NullPointerException 
              at org.apache.maven.project.DefaultProjectDependenciesResolver.resolve(DefaultProjectDependenciesResolver.java:156) 
              at org.apache.maven.lifecycle.internal.LifecycleDependencyResolver.getDependencies(LifecycleDependencyResolver.java:165) 
              ... 22 more 
      Caused by: org.sonatype.aether.resolution.ArtifactResolutionException: Could not transfer artifact org.apache.maven:maven-repository-metadata:jar:2.0.8 from nexus (http://maven/nexus/content/groups/public): NullPointerException 
              at org.sonatype.aether.impl.internal.DefaultArtifactResolver.resolveArtifacts(DefaultArtifactResolver.java:488) 
              at org.sonatype.aether.impl.internal.DefaultRepositorySystem.resolveArtifacts(DefaultRepositorySystem.java:258) 
              at org.sonatype.aether.impl.internal.DefaultRepositorySystem.resolveDependencies(DefaultRepositorySystem.java:288) 
              at org.apache.maven.project.DefaultProjectDependenciesResolver.resolve(DefaultProjectDependenciesResolver.java:150) 
              ... 23 more 
      Caused by: org.sonatype.aether.transfer.ArtifactTransferException: Could not transfer artifact org.apache.maven:maven-repository-metadata:jar:2.0.8 from nexus (http://maven/nexus/content/groups/public): NullPointerException 
              at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$4.wrap(WagonRepositoryConnector.java:858) 
              at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$4.wrap(WagonRepositoryConnector.java:849) 
              at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask.flush(WagonRepositoryConnector.java:602) 
              at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask.flush(WagonRepositoryConnector.java:596) 
              at org.sonatype.aether.connector.wagon.WagonRepositoryConnector.get(WagonRepositoryConnector.java:355) 
              at org.sonatype.aether.impl.internal.DefaultArtifactResolver.resolveArtifacts(DefaultArtifactResolver.java:407) 
              ... 26 more 
      Caused by: java.lang.NullPointerException 
              at org.apache.maven.cli.ConsoleMavenTransferListener.transferProgressed(ConsoleMavenTransferListener.java:60) 
              at org.sonatype.aether.connector.wagon.WagonTransferListenerAdapter.transferProgress(WagonTransferListenerAdapter.java:69) 
              at org.apache.maven.wagon.events.TransferEventSupport.fireTransferProgress(TransferEventSupport.java:124) 
              at org.apache.maven.wagon.AbstractWagon.fireTransferProgress(AbstractWagon.java:505) 
              at org.apache.maven.wagon.AbstractWagon.transfer(AbstractWagon.java:490) 
              at org.apache.maven.wagon.AbstractWagon.getTransfer(AbstractWagon.java:328) 
              at org.apache.maven.wagon.AbstractWagon.getTransfer(AbstractWagon.java:299) 
              at org.apache.maven.wagon.AbstractWagon.getTransfer(AbstractWagon.java:276) 
              at org.apache.maven.wagon.StreamWagon.getIfNewer(StreamWagon.java:97) 
              at org.apache.maven.wagon.StreamWagon.get(StreamWagon.java:61) 
              at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask.run(WagonRepositoryConnector.java:511) 
              at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650) 
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675) 
              at java.lang.Thread.run(Thread.java:595) 
      
      
      
      [ERROR] Failed to execute goal on project stdlib-native: Could not resolve dependencies for project com.mycompany:stdlib-native:jar:3.0.0-SNAPSHOT: Could not transfer artifact org.jboss.security:jbosssx-client:jar:2.0.3.SP1 from nexus (http://maven/nexus/content/groups/public): NullPointerException -> [Help 1] 
      org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal on project stdlib-native: Could not resolve dependencies for project com.mycompany:stdlib-native:jar:3.0.0-SNAPSHOT: Could not transfer artifact org.jboss.security:jbosssx-client:jar:2.0.3.SP1 from nexus (http://maven/nexus/content/groups/public): NullPointerException 
              at org.apache.maven.lifecycle.internal.LifecycleDependencyResolver.getDependencies(LifecycleDependencyResolver.java:190) 
              at org.apache.maven.lifecycle.internal.LifecycleDependencyResolver.resolveProjectDependencies(LifecycleDependencyResolver.java:104) 
              at org.apache.maven.lifecycle.internal.MojoExecutor.ensureDependenciesAreResolved(MojoExecutor.java:244) 
              at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:187) 
              at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:148) 
              at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:140) 
              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:314) 
              at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:151) 
              at org.apache.maven.cli.MavenCli.execute(MavenCli.java:445) 
              at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:168) 
              at org.apache.maven.cli.MavenCli.main(MavenCli.java:132) 
              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:585) 
              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.project.DependencyResolutionException: Could not resolve dependencies for project com.mycompany:stdlib-native:jar:3.0.0-SNAPSHOT: Could not transfer artifact org.jboss.security:jbosssx-client:jar:2.0.3.SP1 from nexus (http://maven/nexus/content/groups/public): NullPointerException 
              at org.apache.maven.project.DefaultProjectDependenciesResolver.resolve(DefaultProjectDependenciesResolver.java:156) 
              at org.apache.maven.lifecycle.internal.LifecycleDependencyResolver.getDependencies(LifecycleDependencyResolver.java:165) 
              ... 22 more 
      Caused by: org.sonatype.aether.resolution.ArtifactResolutionException: Could not transfer artifact org.jboss.security:jbosssx-client:jar:2.0.3.SP1 from nexus (http://maven/nexus/content/groups/public): NullPointerException 
              at org.sonatype.aether.impl.internal.DefaultArtifactResolver.resolveArtifacts(DefaultArtifactResolver.java:488) 
              at org.sonatype.aether.impl.internal.DefaultRepositorySystem.resolveArtifacts(DefaultRepositorySystem.java:258) 
              at org.sonatype.aether.impl.internal.DefaultRepositorySystem.resolveDependencies(DefaultRepositorySystem.java:288) 
              at org.apache.maven.project.DefaultProjectDependenciesResolver.resolve(DefaultProjectDependenciesResolver.java:150) 
              ... 23 more 
      Caused by: org.sonatype.aether.transfer.ArtifactTransferException: Could not transfer artifact org.jboss.security:jbosssx-client:jar:2.0.3.SP1 from nexus (http://maven/nexus/content/groups/public): NullPointerException 
              at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$4.wrap(WagonRepositoryConnector.java:858) 
              at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$4.wrap(WagonRepositoryConnector.java:849) 
              at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask.flush(WagonRepositoryConnector.java:602) 
              at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask.flush(WagonRepositoryConnector.java:596) 
              at org.sonatype.aether.connector.wagon.WagonRepositoryConnector.get(WagonRepositoryConnector.java:355) 
              at org.sonatype.aether.impl.internal.DefaultArtifactResolver.resolveArtifacts(DefaultArtifactResolver.java:407) 
              ... 26 more 
      Caused by: java.lang.NullPointerException 
              at org.apache.maven.cli.ConsoleMavenTransferListener.transferProgressed(ConsoleMavenTransferListener.java:60) 
              at org.sonatype.aether.connector.wagon.WagonTransferListenerAdapter.transferProgress(WagonTransferListenerAdapter.java:69) 
              at org.apache.maven.wagon.events.TransferEventSupport.fireTransferProgress(TransferEventSupport.java:124) 
              at org.apache.maven.wagon.AbstractWagon.fireTransferProgress(AbstractWagon.java:505) 
              at org.apache.maven.wagon.AbstractWagon.transfer(AbstractWagon.java:490) 
              at org.apache.maven.wagon.AbstractWagon.getTransfer(AbstractWagon.java:328) 
              at org.apache.maven.wagon.AbstractWagon.getTransfer(AbstractWagon.java:299) 
              at org.apache.maven.wagon.AbstractWagon.getTransfer(AbstractWagon.java:276) 
              at org.apache.maven.wagon.StreamWagon.getIfNewer(StreamWagon.java:97) 
              at org.apache.maven.wagon.StreamWagon.get(StreamWagon.java:61) 
              at org.sonatype.aether.connector.wagon.WagonRepositoryConnector$GetTask.run(WagonRepositoryConnector.java:511) 
              at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:650) 
              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:675) 
              at java.lang.Thread.run(Thread.java:595)
      

      Attachments

        Activity

          People

            bentmann Benjamin Bentmann
            jgon2 jgon2
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: