0
votes

I am unable to deploy a snapshot artifact to Nexus Repository. I keep getting return code 400. Failed to deploy artifacts: Could not transfer artifact net.iin:iin-web-0.0.1-SNAPSHOT:jar:iin-parent from/to snapshots (http://localhost:8081/nexus/content/repositories/snapshots): Failed to transfer file: http://localhost:8081/nexus/content/repositories/snapshots/net/iin/iin-web-0.0.1-SNAPSHOT/iin-parent/iin-web-0.0.1-SNAPSHOT-iin-parent.jar. Return code is: 400, ReasonPhrase:Bad Request. ERROR: Uploading file iin-web-0.0.1-SNAPSHOT.jar failed.

But the same way I am able to deploy a snapshot artifact to Nexus Repository. Uploading artifact iin-web-0.0.1-SNAPSHOT.jar started.... GroupId: net.iin ArtifactId: iin-web-0.0.1-SNAPSHOT Classifier: Type: jar Version: iin-parent File: iin-web-0.0.1-SNAPSHOT.jar Repository:releases Uploaded: http://localhost:8081/nexus/content/repositories/releases/net/iin/iin-web-0.0.1-SNAPSHOT/iin-parent/iin-web-0.0.1-SNAPSHOT-iin-parent.jar (63 MB at 46 MB/s) Uploading artifact iin-web-0.0.1-SNAPSHOT.jar completed. Finished: SUCCESS

1
Please show your pom file in particular the are distributionManagement...khmarbaise

1 Answers

0
votes

It seems to me that you used the artifactId iin-web-0.0.1-SNAPSHOT. So you probably put the version into the artifactId instead of the version tag.

The result is that Maven considers your (broken) GAV as release version because the version itself does not end in SNAPSHOT.