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

Download of docker manifest via UI fails if there is no history in the manifest

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: New
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 3.30.1
    • Fix Version/s: None
    • Component/s: Docker
    • Labels:
    • Notability:
      3

      Description

      Attempting to download a manifest via the web UI will fail if the manifest has no history:

       

      2021-05-17 12:02:20,635+0000 WARN [qtp454179014-220] admin org.sonatype.nexus.repository.docker.internal.V2Handlers - Error: GET /v2/project/manifests/1.2.3
      java.lang.NullPointerException: Cannot invoke method size() on null object
      at org.codehaus.groovy.runtime.NullObject.invokeMethod(NullObject.java:91)
      at org.codehaus.groovy.runtime.callsite.PogoMetaClassSite.call(PogoMetaClassSite.java:47)
      at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:47)
      at org.codehaus.groovy.runtime.callsite.NullCallSite.call(NullCallSite.java:34)
      at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:47)
      at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
      at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:120)
      at org.sonatype.nexus.repository.docker.internal.V2ManifestConfigDowngrader.downgrade(V2ManifestConfigDowngrader.groovy:33)
      at org.sonatype.nexus.repository.docker.internal.V2ManifestConfigDowngrader$downgrade.call(Unknown Source)
      at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:47)
      at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
      at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:152)
      at org.sonatype.nexus.repository.docker.internal.orient.V2ManifestUtilImpl.mayDowngrade(V2ManifestUtilImpl.groovy:192)
      at org.sonatype.nexus.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:49)
      at org.sonatype.nexus.repository.docker.internal.orient.DockerHostedFacetImpl.getManifestByTag(DockerHostedFacetImpl.java:959)
      at org.sonatype.nexus.transaction.TransactionalWrapper.proceedWithTransaction(TransactionalWrapper.java:57)
      at org.sonatype.nexus.transaction.TransactionInterceptor.proceedWithTransaction(TransactionInterceptor.java:66)
      at org.sonatype.nexus.transaction.TransactionInterceptor.invoke(TransactionInterceptor.java:55)
      at org.sonatype.nexus.repository.docker.internal.DockerHostedFacet$getManifestByTag$9.call(Unknown Source)
      at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:47)
      at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
      at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:144)
      at org.sonatype.nexus.repository.docker.internal.V2Handlers$_closure14.doCall(V2Handlers.groovy:261)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

      Expected: If the history is empty, just keep going with the downgrade. Or even better, perhaps we can detect that the client is a web browser, and not do the downgrade.
       

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            rseddon Rich Seddon
            Last Updated By:
            Rich Seddon Rich Seddon
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Date of First Response:

                tigCommentSecurity.panel-title