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

slow start-up of carta4 beta (2.5 minutes) when no "telemetryUuid" in .carta-beta/config/preferences.json #2304

Closed
fstalm opened this issue Nov 29, 2023 · 6 comments · Fixed by #2317
Assignees
Labels
bug Something isn't working
Milestone

Comments

@fstalm
Copy link

fstalm commented Nov 29, 2023

Describe the bug
When no "telemetryUuid" is in .carta-beta/config/preferences.json then the stand-alone electron version we use takes 2.5 minutes to start up. That seems to also have been the case with a remote usage without the electron app. It also happens when there is no telemetry switched on "telemetryMode": "none". Once a telemetryUuid is set, any ID, e.g.
"telemetryUuid": "1",
the start-up time drops to about 5 seconds.

The process hangs on the frontend after 'compute modules loaded'.

This may be only an issue with our set-up as reported per mail before.

To Reproduce
Set .carta-beta/config/preferences.json to
{
"$schema": "https://cartavis.github.io/schemas/preferences_schema_2.json",
"lastUsedFolder": "",
"telemetryConsentShown": true,
"telemetryMode": "none",
"version": 2
}
start CARTA beta4 backend and frontend.

Expected behavior
Startup within 5-10 seconds

Platform info (please complete the following information):

  • OS RHEL8
  • electron app, but also Firefox
  • Version 4.0.0-beta.1
@kswang1029
Copy link
Collaborator

Was the issue spotted on the alma science archive or in other circumstances? Did you use the same electron app executable for multiple users? I wonder if this is something to do with free port hunting? After 2.5mins, did the application start successfully?

@fstalm
Copy link
Author

fstalm commented Nov 30, 2023

Was the issue spotted on the alma science archive or in other circumstances?
This was spotted using a local CARTA locally on a cluster.

Did you use the same electron app executable for multiple users?
Yes

I wonder if this is something to do with free port hunting?
The backend comes up very quickly indicating the port, the hanging happens on the frontend much later in the process.

After 2.5mins, did the application start successfully?
Yes. If the telemetryUuid is set to any value, then consistently the startup takes less than 10 seconds. If that telemetryUuid is empty or does not exist, the startup of the frontend is 2.5min. And each restart the takes again 2.5 minutes consistently.

@kswang1029
Copy link
Collaborator

Ok after some internal discussions, the issue is likely due to 1) interrupted telemetry server and 2) a too long timeout. We are addressing the issues.

@fstalm
Copy link
Author

fstalm commented Dec 1, 2023

Suggestions: contacting the telemetry server could be spawned off asynchronously in a separate thread for a better user-experience. If the user has opted out of telemetry, the telemetry server must not be contacted in the first place.

@kswang1029 kswang1029 added the bug Something isn't working label Dec 1, 2023
@kswang1029 kswang1029 added this to the v5.0-beta milestone Dec 1, 2023
@crocka
Copy link
Contributor

crocka commented Dec 14, 2023

Hi @fstalm, I am not able to reproduce the error. In addition to trying the procedure you provided above, I tried to change the uuid request url to an invalid one and tried to set an invalid uuid. Both cases resulted in error output in the browser console, but did not obstruct the app from starting. Could you please share with me the error output from the brower console? If you are using the electron version, you can access the console by clicking the "CARTA" button beside the Apple logo at the top left corner of the screen, and then go to "Toggle Developer Tools". At the top of the developer tools, you can choose "console" to show the output log. Also, could you tell me if new token will be generated and saved in preferences.json after waiting for 2.5 min?

@fstalm
Copy link
Author

fstalm commented Dec 19, 2023

As discussed. Thanks @crocka for the fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
No open projects
Status: Backlog
Status: Closed
Development

Successfully merging a pull request may close this issue.

3 participants