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

New remote artifact detection

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Incomplete
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Proxy Repository
    • Labels:
      None

      Description

      This is just for discussion's sake, not for NX2 change implementations (but rather for NX3):

      In NX2, when proxy cached item is expired, NX2 issues a HEAD request to remote to detect if remote item is changed or not. But, only Last-Modified header is used from response to check for remote change (as ETag is not cached, and item size is not passed on).

      HEAD response might contains more meaningful bits, that could be used for change detection:

      • Last-Modified (currently used by NX2, but has second resolution due to date formatting, could be used to craft conditional request)
      • Content-Length (compare cached size and remote size, if known)
      • ETag (should be cached along with item metadata if sent. If known, could be used to craft conditional request, or compare with response contained one)

      Also, HEAD could be swapped for a conditional GET (using request headers like if-modified-since and/or if-match and it's variations).

      This affects NX2 Maven proxies (basically all proxies using HttpClientRemoteStorage as transports), while formats like NPM proxy uses own transport and uses ETag for same purpose (as npm registries must implement ETags).

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            cstamas Tamás Cservenák
            Last Updated By:
            Peter Lynch Peter Lynch
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:
              Date of First Response:

                tigCommentSecurity.panel-title