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
Using vuex on ssr following the ssr guide. I have created an application with a large number of components and modules and therefore a large number of namespaced getters. Every time such a getter is invoked the makeLocalGetters function is called iterating trough all the getters in the store just to create the gettersProxy object. This is overkill for ssr performance and is being flagged as a CPU consuming process in the node profiler.
I have managed to double the number of requests per second my ssr app can handle just by using memoization on the gettersProxy object creation. I think this is really impacting performance.
What is expected?
Namespaced getters invokation not to be inefficient with large numbers of getters/modules
What is actually happening?
A lot of hits to makeLocalGetters making performance go down
The text was updated successfully, but these errors were encountered:
frankcs
changed the title
makeLocalGetters performance hit
makeLocalGetters performance hit on ssr
Apr 23, 2019
Version
3.1.0
Reproduction link
https://codepen.io/frankcs/pen/NmOLNX
Steps to reproduce
Using vuex on ssr following the ssr guide. I have created an application with a large number of components and modules and therefore a large number of namespaced getters. Every time such a getter is invoked the makeLocalGetters function is called iterating trough all the getters in the store just to create the gettersProxy object. This is overkill for ssr performance and is being flagged as a CPU consuming process in the node profiler.
I have managed to double the number of requests per second my ssr app can handle just by using memoization on the gettersProxy object creation. I think this is really impacting performance.
What is expected?
Namespaced getters invokation not to be inefficient with large numbers of getters/modules
What is actually happening?
A lot of hits to makeLocalGetters making performance go down
The text was updated successfully, but these errors were encountered: