Automated Garbage Collection #3240
Unanswered
kurtextrem
asked this question in
Q&A
Replies: 1 comment
-
The quick answer, is yes, nothing is built-in for the store. There is an action you can send that does GC for user-land implementations (https://github.com/reactive/data-client/blob/master/packages/core/src/state/reducer/createReducer.ts#L27) Keep in mind the denormalization cache is garbage collected automatically by the javascript engine, as it is 100% WeakMaps. We're open to design for good generalizable solutions as well as re-prioritization based on need. So far there hasn't been much demand for it, so we've focused on other things. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi, does the data-client implement any sort of automated garbage collection? I've seen that we can call
clear
(NetworkManager) orcleanup
(SubscriptionManager), but I didn't find anything similar to e.g. "after 5min of the data being unused, remove it from cache".I assume it is thus expected that this is done by userland, not the library, right?
Beta Was this translation helpful? Give feedback.
All reactions