-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[preferences][multi root] Potentially exagerated number of calls to getConfigUri() #7631
Comments
I can add that OS was RHEL 7 running the browser example app. |
i found a few things:
|
We should investigate first whether it causes any bad side effects. If not there is nothing to be done. Particularly in each profiling sessions check whether it is the hottest call. |
Anecdotally, I don't think it really slowed anything down until I tried logging it, and then it was almost certainly the logging that slowed things down, not the logic. But this may also be a chance for me to understand part of this system better. @elaihau , you mention the six providers for each folder; could you help me understand why the |
I think we access data in The reason that we have 6 providers per root folder is because, not only do we get data from
i am not sure if i misunderstand you question.
Yep i think so too. so in my experiment i don't log anything until the accumulated run time of that function exceeds a threshold, say, 5 ms. |
@elaihau, thanks that's very helpful! |
@akosyakov From static analysis, I can see that this function is called every time a preference item is retrieved, updated, or initilized. It might have slowed down the startup a little, but I don't think it has major impacts as it doesn't block anything. |
ok, let's move on then Just think about React virtual DOM rendering i'm pretty sure that there are much many calls to our render method, we are not going to rewrite react because of it. |
If there are no objections I am going to close this one in a day. |
Description
Originally reported in this comment: #7105 (comment)
14000 times seems excessive.
@akosyakov 's suggestion:
Reproduction Steps
OS and Theia version:
App: browser example
OS: RHEL 7
Theia version: latest master
Diagnostics:
The text was updated successfully, but these errors were encountered: