Uploaded image for project: 'Dev - Nexus Repo'
  1. Dev - Nexus Repo
  2. NEXUS-19943

Deployment of snapshots using Maven 2.2.1/Gradle fails

    Details

    • Type: Bug
    • Status: New
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 3.16.1, 3.17.0, 3.30.0
    • Fix Version/s: None
    • Component/s: Maven
    • Story Points:
      3
    • Notability:
      2

      Description

      Start up Nexus Repo 3.16.1, and attempt to deploy a snapshot to it using Maven 2.2.1. This will fail with a 400 response:

      [INFO] Error installing artifact's metadata: Error while deploying metadata: Failed to transfer file: http://localhost:8081/repository/maven-snapshots/com/aa/et/project/maven-metadata.xml. Return code is: 400

      The nexus.log shows:

      2019-05-15 16:53:11,423-0400 WARN [qtp828929724-58] admin org.sonatype.nexus.repository.view.handlers.ExceptionHandler - Invalid content: PUT /com/aa/et/project/maven-metadata.xml: org.sonatype.nexus.repository.InvalidContentException: Invalid maven-metadata.xml GAV com.aa.et, project, 1.0.7-SNAPSHOT does not match request path com/aa/et/project/maven-metadata.xml

      I can find no workaround for this, disabling file content validation does not solve it, nor does setting the layout policy to permissive.

      Update:  For a last resort workaround, edit $datadir/etc/nexus.properties and add this line:

      nexus.maven.metadata.validation.enabled=false

      Then restart Nexus.

      Caution: The workaround can cause invalid maven-metadata.xml to be cached inside NXRM, possible leading to other failures downloading corrupt maven-metadata.xml, like NEXUS-26419 and NEXUS-22262 .

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              rseddon Rich Seddon
              Last Updated By:
              Rich Seddon Rich Seddon
              Team:
              NXRM - Mad Max
              Votes:
              5 Vote for this issue
              Watchers:
              12 Start watching this issue

                Dates

                Created:
                Updated:
                Date of First Response:

                  tigCommentSecurity.panel-title