Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.12.1
    • Component/s: Storage
    • Labels:
      None

      Description

      This patch provides a 'hash' value for the stored object.

      There are two approaches possible.
      1) For every object stored / downloaded, calculate the MD5 hash on the fly. Store the cache info in a folder '.hash' - which is excluded from the content listing. Use this cached value in the future. If file time-stamp changes, update the cache
      2) Just provide a MD5 hash of the stat.st_mtime of the file.

      Approach (1) will give a true hash of the object.
      Approach (2) will give an indication about changes in the object. Like an ETag.

      Approach (2) is similar to how S3 storage works. The hash returned by S3 is not the content digest. It is just an ETag. So, in local storage, we can take Approach (2).

      We can migrate to Approach (1) in the future, if required.

        Activity

        Hide
        kami Tomaz Muraus added a comment -

        Local storage driver is not really meant (or should be) used for anything other than playing with the API and testing it so number 1 seems good enough to me.

        Show
        kami Tomaz Muraus added a comment - Local storage driver is not really meant (or should be) used for anything other than playing with the API and testing it so number 1 seems good enough to me.
        Hide
        kami Tomaz Muraus added a comment -
        Show
        kami Tomaz Muraus added a comment - Merged into trunk - http://svn.apache.org/viewvc?view=revision&revision=1426858 . Thanks.

          People

          • Assignee:
            kami Tomaz Muraus
            Reporter:
            mahendra.m Mahendra M
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development