org.apache.maven.plugin.MojoExecutionException: Error deploying artifact: Failed to transfer file: http://dev-tools.further.utah.edu/nexus/service/local/staging/deploy/maven2/edu/utah/further/further/1.0.0-SNAPSHOT/further-1.0.0-20091106.223534-1.pom. Return code is: 400

Sonatype JIRA | Oren Livne | 7 years ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    - Using maven 3.0-SNAPSHOT - settings.xml contains: <servers> <server> <id>nexus</id> <username>deployment</username> <password>****</password> </server> </servers> - When typing "mvn deploy -N -X" for our artifact (edu.utah.further:further:pom), an HTTP 400 error is returned: [ERROR] [0] org.apache.maven.plugin.MojoExecutionException: Error deploying artifact: Failed to transfer file: http://dev-tools.further.utah.edu/nexus/service/local/staging/deploy/maven2/edu/utah/further/further/1.0.0-SNAPSHOT/further-1.0.0-20091106.223534-1.pom. Return code is: 400 at org.apache.maven.plugin.deploy.DeployMojo.execute(DeployMojo.java:195) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:105) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:547) at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:317) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:233) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:102) at org.apache.maven.cli.MavenCli.execute(MavenCli.java:421) at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:156) at org.apache.maven.cli.MavenCli.main(MavenCli.java:121) 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.artifact.deployer.ArtifactDeploymentException: Error deploying artifact: Failed to transfer file: http://dev-tools.further.utah.edu/nexus/service/local/staging/deploy/maven2/edu/utah/further/further/1.0.0-SNAPSHOT/further-1.0.0-20091106.223534-1.pom. Return code is: 400 at org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(DefaultArtifactDeployer.java:85) at org.apache.maven.plugin.deploy.DeployMojo.execute(DeployMojo.java:165) ... 16 more Caused by: org.apache.maven.wagon.TransferFailedException: Failed to transfer file: http://dev-tools.further.utah.edu/nexus/service/local/staging/deploy/maven2/edu/utah/further/further/1.0.0-SNAPSHOT/further-1.0.0-20091106.223534-1.pom. Return code is: 400 at org.apache.maven.wagon.providers.http.LightweightHttpWagon.put(LightweightHttpWagon.java:172) at org.apache.maven.repository.legacy.DefaultWagonManager.putRemoteFile(DefaultWagonManager.java:496) at org.apache.maven.repository.legacy.DefaultWagonManager.putArtifact(DefaultWagonManager.java:450) at org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(DefaultArtifactDeployer.java:75) ... 17 more [ERROR] [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following articles: [ERROR] [0] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException - The deployment user has the proper role. What is the proper way to set up staging? I followed thr instructions in the book but that doesn't seem to work. Thank you in advance.

    Sonatype JIRA | 7 years ago | Oren Livne
    org.apache.maven.plugin.MojoExecutionException: Error deploying artifact: Failed to transfer file: http://dev-tools.further.utah.edu/nexus/service/local/staging/deploy/maven2/edu/utah/further/further/1.0.0-SNAPSHOT/further-1.0.0-20091106.223534-1.pom. Return code is: 400

    Root Cause Analysis

    1. org.apache.maven.wagon.TransferFailedException

      Failed to transfer file: http://dev-tools.further.utah.edu/nexus/service/local/staging/deploy/maven2/edu/utah/further/further/1.0.0-SNAPSHOT/further-1.0.0-20091106.223534-1.pom. Return code is: 400

      at org.apache.maven.wagon.providers.http.LightweightHttpWagon.put()
    2. Maven
      LightweightHttpWagon.put
      1. org.apache.maven.wagon.providers.http.LightweightHttpWagon.put(LightweightHttpWagon.java:172)
      1 frame
    3. Maven Compat
      DefaultWagonManager.putArtifact
      1. org.apache.maven.repository.legacy.DefaultWagonManager.putRemoteFile(DefaultWagonManager.java:496)
      2. org.apache.maven.repository.legacy.DefaultWagonManager.putArtifact(DefaultWagonManager.java:450)
      2 frames
    4. Maven
      DefaultArtifactDeployer.deploy
      1. org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(DefaultArtifactDeployer.java:75)
      1 frame
    5. org.apache.maven
      DeployMojo.execute
      1. org.apache.maven.plugin.deploy.DeployMojo.execute(DeployMojo.java:165)
      1 frame
    6. Maven Plugin
      DefaultBuildPluginManager.executeMojo
      1. org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:105)
      1 frame
    7. Maven Core
      DefaultMaven.execute
      1. org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:547)
      2. org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:317)
      3. org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:233)
      4. org.apache.maven.DefaultMaven.execute(DefaultMaven.java:102)
      4 frames
    8. M3 Interceptor
      MavenCli.main
      1. org.apache.maven.cli.MavenCli.execute(MavenCli.java:421)
      2. org.apache.maven.cli.MavenCli.doMain(MavenCli.java:156)
      3. org.apache.maven.cli.MavenCli.main(MavenCli.java:121)
      3 frames
    9. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
      3. sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      4. java.lang.reflect.Method.invoke(Method.java:597)
      4 frames
    10. Plexus
      Launcher.main
      1. org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
      2. org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
      3. org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
      4. org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
      4 frames