Uploaded image for project: 'Artifactory Binary Repository'
  1. Artifactory Binary Repository
  2. RTFACT-20293

Artifactory remote repositories are making redundant GET requests when you enable Bypass HEAD requests option

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: High
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: NPM, Remote Repository
    • Labels:

      Description

      Artifactory remote repositories are making redundant GET requests when you enable Bypass HEAD requests. For example with NPM remote repository if you enable Bypass HEAD requests in remote repo settings, the Remote repository ends up making two identical GET requests for the same package. The two GET requests are seen for both metadata and the actual tarball package as well. 

      Artifactory version - 6.X

      Please note that the two GET requests Artifactory is making cannot be seen in the Artifactory request logs. You will need a proxy server to capture the transactions from Artifactory to the upstream npmjs, which will show the two GET requests. I have attached a screenshot of the charles proxy console showing the redundant GET requests.

      This issue affects anyone who is using Bypass HEAD requests option in the NPM remote repositories, as we are now sending double the number of requests to the upstream npmjs. 

      Making two GET requests for the same binary is not good, as you could be in a situation where one GET request could hit a CDN cache that has the updated metadata and the second GET could hit a CDN cache that has older metadata. CDN caches being out of sync is something that can happen and lead to inconsistencies in Artifactory when making multiple GET requests for the same binary or metadata.

      Steps to Reproduce:

      1. Create a NPM remote repository. In Advanced settings page please enable Bypass Head requests
      2. Now have a forward proxy, so that you can monitor every request going out of Artifactory.
      3. Try installing a NPM package and you will notice in the Proxy logs that Artifactory is making two GET requests for metadata of the package and also for the actual tarball as well

        Attachments

          Activity

            People

            Assignee:
            Unassigned
            Reporter:
            nihalc@jfrog.com Nihal Reddy Chinna Choudhary
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated: