1
votes

First let me point out what exactly is happening.

  1. Am able to do a successful snapshot as well as release build from local workstation. Artifacts are also successfully uploaded to nexus.

  2. We have a central hudson installation used by many teams/developers. Snapshot build working successfully from Hudson

  3. Release build for a particular project fails from Hudson with the following error:

    [INFO] Uploading: https://nlliprdcn28098.nl.eu.abnamro.com:8443/nexus/content/repositories/SF_DRA-releases/com/abnamro/gsfg/sigt/reports/dra/sf_dra/1.19/sf_dra-1.19.pom [INFO] [DEBUG] Using Wagon implementation lightweight from default mapping for protocol https [INFO] [INFO] ------------------------------------------------------------------------ [INFO] [ERROR] BUILD ERROR [INFO] [INFO] ------------------------------------------------------------------------ [INFO] [INFO] Error deploying artifact: Failed to transfer file: https://nlliprdcn28098.nl.eu.abnamro.com:8443/nexus/content/repositories/SF_DRA-releases/com/abnamro/gsfg/sigt/reports/dra/sf_dra/1.19/sf_dra-1.19.pom. Return code is: 401 [INFO] [INFO] [INFO] ------------------------------------------------------------------------ [INFO] [DEBUG] Trace [INFO] org.apache.maven.lifecycle.LifecycleExecutionException: Error deploying artifact: Failed to transfer file: https://nlliprdcn28098.nl.eu.abnamro.com:8443/nexus/content/repositories/SF_DRA-releases/com/abnamro/gsfg/sigt/reports/dra/sf_dra/1.19/sf_dra-1.19.pom. Return code is: 401 [INFO] at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:719) [INFO] at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:556) [INFO] at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:535) [INFO] at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387) [INFO] at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348) [INFO] at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180) [INFO] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)

Now, the points to note:

  1. Settings file is proper as the same is working from local
  2. User has access to upload to nexus
  3. Same artifact NOT present in nexus
  4. Only difference between local and hudson settings are that in hudson the password are encrypted. But the same encrypted password is working for release job of a diff project but failing for this.

Hudson ver. 1.377 Maven 2.2.1, Nexus : 1.9.2.3

1

1 Answers

0
votes

If you can deploy snapshot and releases from your local workstation and the settings.xml for jenkins are similar than check your version 1.19 from your release for the file: sf_dra-1.19.pom, it could be that you allready released from your local workstation and maven can not deploy the same release number more then one time. So delete the released files from nexus, and remove also tags form your svn or git. then you can release again with the same number.