cloudfuse icon indicating copy to clipboard operation
cloudfuse copied to clipboard

Minor improvements in file cache

Open foodprocessor opened this issue 1 year ago • 0 comments

Describe your changes in brief

In file cache test suite:

  • Re-enable tests that were flaky due to race conditions that are fixed now
  • Shorten a couple test sleep times
  • Remove unnecessary OpenFile when timeout is non-zero
  • Remove redundant call to setupTestHelper with config identical to test default config

In lru_policy:

  • Remove unused const
  • Simplify cacheTimeoutMonitor code
    • (calling time.Tick with a zero interval already returns nil, so no need to check if the interval is zero)
  • Add comments to updateMarker to explain linked list code

What type of Pull Request is this? (check all applicable)

  • [ ] Refactor
  • [ ] Feature
  • [ ] Bug Fix
  • [ ] Optimization
  • [ ] Documentation Update

Checklist

  • [ ] Tested locally
  • [ ] Added new dependencies
  • [ ] Updated documentation
  • [ ] Added tests

Related Issues

  • Related Issue #
  • Closes #

foodprocessor avatar Sep 28 '24 04:09 foodprocessor