You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In order to safely prune old content after storing fresh content in the cache, we need some means of knowing if the old content has now become orphaned. The fastest approach to this is reference counting.
Implementation will require
actually implementing reference counting
automating migration of old cache stores to deduplicate references and count them
The text was updated successfully, but these errors were encountered:
We could do the slow migration/pruning step should probably run whenever cacache.verify() is called. The cli runs this as part of npm doctor, but we can also tell the user to do it if cacache doesn't have the ref counting folder.
Also, we need to ensure that cacache still operates properly if ref counts are missing. I'd probably lean towards only updating ref counts if there is one already, and only add them for new items added to the cache, so we don't end up in a situation where it says "references: 1" for something that actually has a bunch of references on it.
What / Why
In order to safely prune old content after storing fresh content in the cache, we need some means of knowing if the old content has now become orphaned. The fastest approach to this is reference counting.
Implementation will require
The text was updated successfully, but these errors were encountered: