Home > Return Code > Error Deploying Artifact Failed To Transfer File Return Code Is 401

Error Deploying Artifact Failed To Transfer File Return Code Is 401

Contents

Taxiing with one engine: Is engine #1 always used or do they switch? I was so focused in the Stack trace that I didn't read the last lines of the build before the Reactor summary and the stack trace: [DEBUG] Using connector AetherRepositoryConnector with If this HTTPS server uses a certificate signed by a CA represented in the bundle, the certificate verification probably failed due to a problem with the certificate (it might be expired, Return code is: 401, ReasonPhrase: Unauthorized. -> [Help 1] dkayiwa (Daniel Kayiwa) 2015-08-06 13:56:29 UTC #2 Did you check out the troubleshooting section at the bottom of this page? have a peek here

In the Jenkins configuration for the failing project, we have a section in the 'Post Build' actions entitled 'Deploy Artifacts To Maven Repository'. posted 2 years ago Also, where is your settings.xml file located? share|improve this answer answered Jul 18 '14 at 18:28 John 1,3841230 1 Unbelievable. at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:216) 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:116) at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80) at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51) at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:120) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:347) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:154) at org.apache.maven.cli.MavenCli.execute(MavenCli.java:584) at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:213) at org.apache.maven.cli.MavenCli.main(MavenCli.java:157) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) http://blog.sonatype.com/2010/11/what-to-do-when-nexus-returns-401/

Error Deploying Artifact Failed To Transfer File Return Code Is 401

at org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(DefaultArtifactDeployer.java:143) at org.apache.maven.plugin.deploy.AbstractDeployMojo.deploy(AbstractDeployMojo.java:167) at org.apache.maven.plugin.deploy.DeployMojo.execute(DeployMojo.java:149) ... 21 more Caused by: org.eclipse.aether.deployment.DeploymentException: Failed to deploy artifacts: Could not transfer artifact com.github.aliteralmind:xbnjava:pom:0.1.2 from/to sonatype-nexus-staging (https://oss.sonatype.org/service/local/staging/deploy/maven2/): Failed to transfer file: https://oss.sonatype.org/service/local/staging/deploy/maven2/com/github/aliteralmind/xbnjava/0.1.2/xbnjava-0.1.2.pom. share|improve this answer answered Nov 18 '14 at 13:34 betty 317 I got the same "Could not find metadata" debug message but the actual error was another one: I Changing it to 0.1.0 ("earlier"), or 0.1.2a, or 0.1.3 ("later") results in the error I was dealing with before this one: –aliteralmind Jul 18 '14 at 18:46 [ERROR] Failed I am experiencing the same issue with a user that has been granted full permissions to the target repository.

  • Hide Permalink Alberto Corral added a comment - 04/16/13 08:04 AM - edited Thanks Rich.
  • asked 3 years ago viewed 19287 times active 3 years ago Visit Chat Linked 1 Maven Unable to deploy in nexus Related 2Deploy Maven artifacts on Sonatype Nexus repository hosted on
  • Here's the error I'm getting when calling mvn deploy (full logs at the bottom): [INFO] BUILD FAILURE [ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.7:deploy (default-deploy) on project xbnjava: Failed to deploy artifacts:
  • Steven_Emmerson (Steven Emmerson) 2012-06-29 18:27:00 UTC #4 I found the problem: I was using Maven's hash of the password for the Gradle password rather than the password itself, so copying the
  • Checklist item 2.

Thanks for the support! Show Rich Seddon added a comment - 04/15/13 06:09 PM An SSL certificate error will not give you a 401 response. You will get a 401 Unauthorized error if you supply the wrong credentials (password etc). Mng-4469 All of sudden, our CI server here at PIH is unable to deploy to mavenrepo with error listed below--last successful upload was at 1:40pm yesterday.

May be the solution is here http://stackoverflow.com/questions/1650596/how-do-i-import-a-new-java-ca-cert-without-using-the-keytool-command-line-utilit Show Alberto Corral added a comment - 04/15/13 05:19 PM I'm having this problem also. I ran it again with the -k option, and this time got only this: Couldn't read data from file "pom.xml", this makes an empty POST. Why isn't the religion of R'hllor, The Lord of Light, dominant? http://stackoverflow.com/questions/20570009/deploying-artifacts-in-nexus-from-maven-gives-error-return-code-is-401 Terms of Service Privacy Policy Copyright© 2008-present, Sonatype Inc.

It only succeeds with a user granted global admin privileges, so there may be more than one related issue here. Maven Deploy Username Password I am just hitting wall after wall with Maven. Do you think I am missing something? Return code is: 401, ReasonPhrase: Unauthorized.

Error Deploying Artifact Failed To Transfer File Return Code Is 400

Post Reply Bookmark Topic Watch Topic New Topic Boost this thread! It seems possible there may be some unknown ones, so if you run into this feel free to file a distinct ticket with a reproduce case. Error Deploying Artifact Failed To Transfer File Return Code Is 401 Show Thomas Keys added a comment - 12/08/16 06:38 PM Update to my comment above - managed to get this to work using newest version of Maven (3.3.9). Return Code Is 401 Reasonphrase Unauthorized. Artifactory To solve this you need to add a server for the module repo by adding the following with Nexus repository credentials to the list of servers in the file /M2_HOME/settings.xml.

In this case use code curl -u username:password --request PUT --data target/api-1.0-SNAPSHOT.jar http://url/artifactory/libs-snapshot-local/com/myproject/api‌/1.0-SNAPSHOT/api-1.‌0-20160128.114425-1.‌jar instead –TouDick Jul 5 '16 at 11:08 add a comment| up vote 2 down vote just change in navigate here Issue Links testing discovered NEXUS-11872 Deleting a repository with an item in it errors in nexus.log Open Bamboo Branches NX3-IFNS440 - Unknown NX3-IFNS440 NX3-INTF1519 - Unknown NX3-INTF1519 NX3-INTF1545 - Unknown NX3-INTF1545 It seems that 0.1.2-SNAPSHOT, which is already created, interferes with my new 0.1.2 version, as you suggest. Apache Maven and Maven are trademarks of the Apache Software Foundation. Failed To Deploy Artifacts Could Not Transfer Artifact Return Code Is 400 Reasonphrase Bad Request

Electrical Propulsion Thrust Is the use of username/password in a mobile app needed? Also, I have notice that when I ran with -X potion it said could not find metadata. Checking the "authorization and authentication" system feed in the Nexus UI can help narrow this down. Check This Out Not the answer you're looking for?

It seems possible there may be some unknown ones, so if you run into this feel free to file a distinct ticket with a reproduce case. Error Deploying Artifact Failed To Transfer File Return Code Is 500 Home Categories FAQ/Guidelines Terms of Service Privacy Policy Powered by Discourse, best viewed with JavaScript enabled FAQs Search RecentTopics FlaggedTopics HotTopics Best Topics Register / Login Post Reply Bookmark Topic Watch This has a 'Repository ID' field which was set to the wrong value.

at org.eclipse.aether.internal.impl.DefaultDeployer.deploy(DefaultDeployer.java:337) at org.eclipse.aether.internal.impl.DefaultDeployer.deploy(DefaultDeployer.java:268) at org.eclipse.aether.internal.impl.DefaultRepositorySystem.deploy(DefaultRepositorySystem.java:413) at org.apache.maven.artifact.deployer.DefaultArtifactDeployer.deploy(DefaultArtifactDeployer.java:139) ... 23 more Caused by: org.eclipse.aether.transfer.ArtifactTransferException: Could not transfer artifact com.github.aliteralmind:xbnjava:pom:0.1.2 from/to sonatype-nexus-staging (https://oss.sonatype.org/service/local/staging/deploy/maven2/): Failed to transfer file: https://oss.sonatype.org/service/local/staging/deploy/maven2/com/github/aliteralmind/xbnjava/0.1.2/xbnjava-0.1.2.pom.

I would suspect the username or password except that they were explicitly copied from my settings.xml file and the Maven deployment works. Browse other questions tagged java maven or ask your own question. How to bevel only one end of a cylinder? Maven Unauthorized See here for an overview: http://www.sonatype.com/books/nexus-book/reference/confignx-sect-managing-privs.html Show Rich Seddon added a comment - 06/04/12 01:13 PM Nexus doesn't ship with fine grained control of repositories, but you can easily add privileges

wyclif (Wyclif Luyima) 2016-02-18 21:04:25 UTC #6 May be they're having authentication issues in nexus that have nothing to do with us Home Categories FAQ/Guidelines Terms of Service Privacy Policy Powered at org.eclipse.aether.connector.wagon.WagonRepositoryConnector$6.wrap(WagonRepositoryConnector.java:1016) at org.eclipse.aether.connector.wagon.WagonRepositoryConnector$6.wrap(WagonRepositoryConnector.java:1004) at org.eclipse.aether.connector.wagon.WagonRepositoryConnector$PutTask.run(WagonRepositoryConnector.java:895) at org.eclipse.aether.connector.wagon.WagonRepositoryConnector.put(WagonRepositoryConnector.java:522) at org.eclipse.aether.internal.impl.DefaultDeployer.deploy(DefaultDeployer.java:331) ... 26 more Caused by: org.apache.maven.wagon.TransferFailedException: Failed to transfer file: https://oss.sonatype.org/service/local/staging/deploy/maven2/com/github/aliteralmind/xbnjava/0.1.2/xbnjava-0.1.2.pom. You can check this by running mvn help:effective-settings. this contact form Make sure to drop the repo you just created.

Briefly speaking, a '401' error occurs when the server asks for user authentication but the client can not provide it. Return code is: 401, ReasonPhrase: Unauthorized. Word for unproportional punishment? at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:216) ---------------------------------------------------------------------------------------------------------- Here is POM.xml 4.0.0 org.bhavesh my-test 1.0-SNAPSHOT jar my-test http://maven.apache.org UTF-8 junit junit 3.8.1 test

Show Peter Lynch added a comment - 12/12/16 06:19 PM An upstream Maven HTTP Wagon issues has been reported and fixed to prevent this on the Maven side: https://issues.apache.org/jira/browse/WAGON-469 Not sure Without more details, it's pretty hard to tell what's going wrong. Run mvn with -e -X options and check the debug output. Return code is: 401, ReasonPhrase: Unauthorized.

up vote 4 down vote favorite 2 I am getting 401 error while deploying in nexus. If credentials were sent there will be an entry in the feed. You also get an error (and off the top of my head is also a 401) if you try to publish something to a releases repository and that version already exists