Ok, I have an artifact release in version x.y.z and I want to redeploy it automatically without changing it's version (I can't change the version!).
The artifact it's divided in three jars that are generated separately. So I have:
They all have the same version. When I'm deploying a SNAPSHOT version I have no problem. But when I deploy the release nexus throws this error inside jenkins console:
Caused by: org.apache.maven.wagon.TransferFailedException: Failed to transfer file:
http://myNexus/nexus/content/repositories/releases/my/package/project/x.y.z/jar-file-x.y.z.jar.
Return code is: 400, ReasonPhrase: Bad Request.
Of course the problem it's that I'm deploying more than one release artifact in a version that obviously need to be unique. But I really need to deploy it that way. Is there a way to force nexus to accept a release more than once?
I think you have to update the Deployment Policy for the release repository. Instead of "Disable Redeploy" it should be set to "Allow Redeploy". More information on this topic can be found in the sonatype nexus book.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With