Skip to content

Add support for contentAccessDate-based expiry and cleanup using custom expiry period #345

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

Rohan-cod-intouch
Copy link

This PR adds support for cache cleanup based on a custom expiry period using the file’s contentAccessDate.

  • Added a new removeExpiredObjects(expiryPeriod:) function.

  • This compares the current time with each file’s contentAccessDate (if available) or modificationDate as a fallback.

  • If the file hasn’t been accessed within the specified expiryPeriod, it is removed from the cache.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant