Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 502292

Summary: Orion occasionally hangs on loading. Suspected incorrect state in session or local storage
Product: [ECD] Orion Reporter: Robert Spies <wilford>
Component: NodeAssignee: Casey Flynn <caseyflynn>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P2 CC: caseyflynn, Michael_Rennie, Silenio_Quarti, steve_northover
Version: unspecified   
Target Milestone: 14.0   
Hardware: PC   
OS: Linux   
See Also: https://git.eclipse.org/r/88422
https://git.eclipse.org/c/orion/org.eclipse.orion.client.git/commit/?id=0db184083b903815e81f0b3d7838b2cb9ae04584
Whiteboard:

Description Robert Spies CLA 2016-09-27 14:09:53 EDT
When running orion (installing using 'npm install orion') we are seeing occasional issues where orion hangs at the loading screen.  There are a number of 500 errors in the console.

Our guess we there was something incorrect/corrupted in the session/localstorage, so our workaround was to use a dynamic URL each time we start orion, thusly getting a fresh session/local storage state.  This "fixed" the issue, which seems to confirm our hypothesis.
Comment 1 Steve Northover CLA 2016-09-27 15:03:49 EDT
Robert, can you verify that the problem still happens using the latest integration build or the latest from the git repo?

Thanks

http://download.eclipse.org/orion/drops/I20160926-2212/index.html
Comment 2 Steve Northover CLA 2016-11-01 16:29:17 EDT
Robert, is the problem still happening?
Comment 3 Michael Rennie CLA 2016-11-01 17:35:13 EDT
I got into this state recently, and we found that is was caused by a core plugin (at one time) failing to load correctly, which put the cached state into a bad state, which caused the 'infinite loading' problem.

I opened bug 506300 for a possible way to prevent / fix it, but I think this is still an issue.
Comment 4 Steve Northover CLA 2016-11-03 12:04:45 EDT
Seems like we just need to debug this.  Need to see the 500's in the console and any other information available when this happens.
Comment 5 Casey Flynn CLA 2017-01-10 14:42:50 EST
It appears that invalid / corrupting the following values in localStorage can cause this issue without throwing an error to the JS console:

/orion/preferences/default/inlineSearchPane
/orion/preferences/default/problemsView
/orion/preferences/default/runBar
/orion/preferences/default/themes
/orion/preferences/default/workspace

/orion/preferences/user/inlineSearchPane
/orion/preferences/user/plugins
/orion/preferences/user/problemsView
/orion/preferences/user/runBar
/orion/preferences/user/themes
/orion/preferences/user/workspace

And the following setting in sessionStorage:

/MiniNav/workspace<name>/uiStateselection

At a minimum if these values are corrupt they should provide error output. It would be nice we could re-initialize the corrupted default values, and fall back on default values should user values become corrupt.
Comment 6 Casey Flynn CLA 2017-01-10 15:48:43 EST
Steps to reproduce:

1) Load Orion.
2) Open developer console.
3) Set the value of one of the localSettings to a non-json object
   (example:localStorage["/orion/preferences/default/themes"] = "notJSON"
4) Reload the page.
Comment 7 Eclipse Genie CLA 2017-01-10 19:08:35 EST
New Gerrit change created: https://git.eclipse.org/r/88422
Comment 8 Steve Northover CLA 2017-01-11 11:38:38 EST
SSQ, please review this change.
Comment 10 Steve Northover CLA 2017-01-17 16:01:10 EST
Ok, SSQ ain't around.  MR?
Comment 11 Michael Rennie CLA 2017-01-17 17:48:38 EST
(In reply to Steve Northover from comment #10)
> Ok, SSQ ain't around.  MR?

I think we can close this, ssq already +2'd and merged it (I also think the changes look good). Simply removing the bad entries will cause them to be re-initialized when used in Orion.