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

repositories with version policy of RELEASE should avoid processing any SNAPSHOT related requests

    XMLWordPrintable

    Details

    • Notability:
      3

      Description

      Create a proxy repository with Version Policy of release ( the default maven-central repo is configured this way ).

      When an inbound request arrives at a path that looks like a SNAPSHOT type request, NXRM will still handle the request as if it is a valid path the repository could support. This will subsequently send a corresponding request outbound from NXRM to a remote that a NX admin is already expecting does not support SNAPSHOT versions.

      The whole point of having a version policy defined is to throw out and reduce the number of repositories to process a request for a group repo request, and also prevent needless requests that will always( or are expected to) 404 at the remote.

      Example:

      NXRM 2, this returns 404 and does NOT trigger an outbound request ( how it is supposed to work): http://localhost:8081/nexus/content/repositories/central/com/example/example/0.1.028-SNAPSHOT/maven-metadata.xml

      NXRM 3, this does trigger an outbound request:
      http://localhost:8081/repository/maven-central/com/example/example/0.1.028-SNAPSHOT/maven-metadata.xml

      Workaround

      To help enforce the version policy to releases, create a routing rule with Mode BLOCK and include the pattern Matcher of

      .*SNAPSHOT.*
      

      then assign that to the repository with the release version policy. You may still encounter issue: NEXUS-12249

      Expected

      For a Maven format repository, if the version policy of the repo is set to RELEASES, throw out the repository with that policy as early as possible when processing an inbound request that is for a SNAPSHOT request.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              mpiggott Matthew Piggott
              Reporter:
              plynch Peter Lynch
              Last Updated By:
              Michael Prescott Michael Prescott
              Team:
              NXRM - Groot
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Date of First Response:

                  tigCommentSecurity.panel-title