Skip to content
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

Update check for installed VS Code Extensions is making time to usable GUI very slow #9056

Open
slhultgren opened this issue Feb 11, 2021 · 2 comments
Labels
open-vsx issues related to the open-vsx registry performance issues related to performance vsx-registry Issues related to Open VSX Registry Integration

Comments

@slhultgren
Copy link
Contributor

Bug Description:

During Theia startup and initialization of the VSXExtensionModel, each vs code extension will be checked against open-vsx.org for update.
The usable GUI is not shown until these update checks has completed.

If you are on a slow network or have a lot of extensions installed (since open-vsx is also rate limited) this will take a long time
With 75 VS Code extensions installed and running Theia in the browser I get this timing of Refresh to GUI: between 50 and 90 seconds.

If I remove this line https://github.com/eclipse-theia/theia/blob/master/packages/vsx-registry/src/browser/vsx-extensions-model.ts#L67

And try the same thing, still with 75 vs code extensions installed, I get Refresh to GUI at a pretty stable 16 seconds for "theia build --mode development"

IMO This update check should be triggered as a background task after the main GUI has been presented.

Steps to Reproduce:

  1. Install a fair number of VS Code extensions
  2. Refresh/restart the Theia instance
  3. Observe that the spinning wheel does not disappear until all the queries against open-vsx has resolved (using network tab in debug tools)

Additional Information

  • Operating System: Linux
  • Theia Version: 1.10.0
@vince-fugnitto vince-fugnitto added open-vsx issues related to the open-vsx registry performance issues related to performance vsx-registry Issues related to Open VSX Registry Integration labels Feb 11, 2021
@vince-fugnitto
Copy link
Member

@slhultgren thank you for reporting the issue, do you have any suggestions on how to improve the performance without a loss of functionality? The initInstalled is used to populate the view (installed and builtins), its possible that this should not be awaited so it does not block the application.

@slhultgren
Copy link
Contributor Author

@vince-fugnitto I need to dig deeper into the updateInstalled() to give a good answer to why we thought we needed to await this function initially.
For now I have not noticed anything obvious by just removing it, or even putting the entire try { update } catch {} block in a setTimeout 60 seconds also seems to do the trick.

I did try just removing the await part but that alone does not solve the issue since it seems the queries to open-vsx are still awaited before presenting the GUI for some reason. I'm hoping to have some time in the coming days to maybe dig into this a bit more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
open-vsx issues related to the open-vsx registry performance issues related to performance vsx-registry Issues related to Open VSX Registry Integration
Projects
None yet
Development

No branches or pull requests

2 participants