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

Staging move for Maven checks unnecessary maven metadata

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: New
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Maven, Staging
    • Story Points:
      5
    • Notability:
      3

      Description

      ISSUE:

      It looks like moving one GAV with the staging API triggers checking all maven metadata in the same group.
      Each check is fast (20 ~ 30 ms) but when there are a few thousands GAVs in the group, the staging API can take a few minutes or more to complete.

      REPRODUCE STEPS

      1. Create two hosted repositories: maven-hosted and maven-releases
      2. Generate dummy data (please check 55985_prepare.sh )
      3. Enable DEBUG logging for "org.sonatype.nexus.repository.maven.internal"
      4. Move only one version 1.8:
        curl -D- -u admin:admin123 -X POST 'http://localhost:8081/service/rest/v1/staging/move/maven-releases?repository=maven-hosted&maven.groupId=test.example55985&maven.artifactId=my-app1&maven.baseVersion=1.8'

      EXPECTED BEHAVIOUR:

      In the nexus.log, not many DEBUG logging line: org.sonatype.nexus.repository.maven.internal.hosted.metadata.MetadataBuilder - -> GAbV: ...
      Or, if this check is necessary, it should be checked parallely.

      ACTUAL BEHAVIOUR:

      It checked 26 GAVs:

      $ grep -E 'qtp887917427-129.+MetadataBuilder - -> GAbV' ./sonatype-work/nexus3/log/nexus.log -c
      26
      

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            hosako Hajime Osako
            Last Updated By:
            Grace Lee Grace Lee
            Team:
            NXRM - Mad Max
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:

                tigCommentSecurity.panel-title