Giter Site home page Giter Site logo

Comments (2)

epsniff avatar epsniff commented on July 3, 2024

This would be a big optimization for some access patterns. Ill take some time to think about the changes need for this.

Off hand I believe we'd have too:

  • Which the store to use a UUID per store cachedir (not per object), to avoid issues with multiple stores on the same system trying to cleanup each others files. *Or we use filelocks but meh..
  • Change OpenFile so it pulls the metadata first, then uses the metadata Hash to check for the presence of the cached file with the same Hash.
  • Update the LastModified data for the cache file each time it's Opened?
  • Keep a counter of Opens on the cache file, increment in OpenFile and decrement in obj.Close(). *Or use filelocks...
  • Make a number of changes to https://github.com/lytics/cloudstorage/blob/master/cachecleaner.go to have it be smarter about what to clean up... Check openfile counts,
  • Possibly : make the cache cleanup configurable with settings so the files can be cleaned up by LeastRecently used: MaxFileCount, MaxAge, MaxBytes... We could get even smarting and enforce a %free for the disk [Shrug].

from cloudstorage.

JayCeeJr avatar JayCeeJr commented on July 3, 2024

This would be great, looks like it has been sitting a while.

As far as s3 goes we could utilize the ETag to verify if the backend file has changed.

from cloudstorage.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.