Can I purge old and outdated cache files?
See original GitHub issueFeature request
On out CI system we upload webpack’s cache to a storage after each build and download them on the next build to speed up build.
After about 6 months, we find there is a 800MB cache directory with more than 100 .pack
files in this cache, causing slower and slower download time.
What is the expected behavior?
We’d like to see an API to purge outdated cache content from these files, we can then run purge monthly, a slow purge process is acceptable since this runs only once per month.
What is motivation or use case for adding/changing the behavior?
Try to limit cache size in long term.
How should this be implemented in your opinion?
Maybe we should have a {purge: true}
in cache
configuration
Are you willing to work on this yourself?
Not able to do that
Issue Analytics
- State:
- Created 2 years ago
- Reactions:3
- Comments:18 (7 by maintainers)
Top Results From Across the Web
Clear Cache vs. Purge Expired Cache in Joomla 2.5
If you purge expired cache, Joomla 2.5 will only delete cache files older than the specified time, which in our example is 30...
Read more >How to clear cache on Mac? Here's our guide - MacPaw
Generally, it is absolutely safe to remove cache because the apps you install or browsers you use will create new cache files when...
Read more >Deleting Cache Files - Ask Tim Grey
In this case you probably only need to delete the older cache, but if you delete both a new cache folder will be...
Read more >Shield Your Internet History: How to Clear Your Cache on Any ...
Go to the three-dot menu at the upper right of Chrome to select More tools > Clear browsing data. This will open a...
Read more >Is it safe to delete everthing in Caches … - Apple Community
*Hello there. As the topic name says, is it safe to delete everything in the caches folder?* *The reason why I want to...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
You can set
infrastructureLogging: { level: "verbose" }
to get a few more lines of logging about the caching.On short term we want to fix the cache issue by removing all unused files from the cache directory after writing the cache. That sounds easy but actually it a bit tricky since, due to lazy deserialization of the cache, we don’t know all files that are currently in use. We might change the cache format a little bit to know these details.
Is there any progress on this issue?