Would it be a good idea to store documents using AsyncLocalStorage? #12831
TubbyStubby
started this conversation in
General
Replies: 1 comment 1 reply
-
I think this is more of a question for whatever mobile app dev framework you use. Depending on implementation, using too much memory and/or making code very complex are both potential issues. Cache invalidation too - fetch an updated document, but forget to update the document in the map could be a problem. Hard to tell without knowing more about your code base. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
So, I have an Api server which was made to serve a specific mobile app. The issue some of the services are very complex and need to interact with multiple models and number of queries has increased a lot. I was thinking if it would be a good idea to create a Map in AsyncLocalStorage to keep all the queried documents for the ongoing request.
I have checked the code and I think it won't cause any concurrency issues, but I am worried about if this can lead to any other issues, like consuming too much memory, make code very complex or something which I never thought of.
Would like to know any of your thoughts on this.
Beta Was this translation helpful? Give feedback.
All reactions