Bug 508419

Summary: Verify thread safety of code called from ResourcesPlugin#start() now that most of it is performed in a background job
Product: [Eclipse Project] Platform Reporter: Mikaël Barbero <mikael.barbero>
Component: ResourcesAssignee: Mikaël Barbero <mikael.barbero>
Status: CLOSED WONTFIX QA Contact:
Severity: normal    
Priority: P3 CC: daniel_megert, eclipse.sprigogin, Lars.Vogel, loskutov
Version: 4.7   
Target Milestone: 4.7 RC1   
Hardware: All   
OS: All   
See Also: https://bugs.eclipse.org/bugs/show_bug.cgi?id=507092
Whiteboard:
Bug Depends on:    
Bug Blocks: 501997    

Description Mikaël Barbero CLA 2016-11-30 02:49:25 EST
See bug 501997 which introduces this background job.
Comment 1 Sergey Prigogin CLA 2017-01-17 15:02:03 EST
Mikaël do you plan to address this issue by M5?
Comment 2 Mikaël Barbero CLA 2017-01-17 20:52:27 EST
Unfortunately I won't have time to look into it by M5. Moving to M6
Comment 3 Andrey Loskutov CLA 2017-01-18 16:40:19 EST
Some time ago I've started to analyse possible side effects, unfortunately I had no time ro complete, below my notes. 

org.eclipse.core.resources.ResourcesPlugin.constructWorkspace()
    -> org.eclipse.core.internal.resources.LocalMetaArea.createMetaArea()
    -> org.eclipse.core.internal.resources.Workspace.clear(File)
    -> org.eclipse.core.filesystem.EFS.getLocalFileSystem()
    -> org.eclipse.core.internal.filesystem.InternalFileSystemCore.getFileSystem(String)
    can create N instances and return to clients


org.eclipse.core.resources.ResourcesPlugin.initializePreferenceLookupOrder()
    -> org.eclipse.core.internal.preferences.PreferencesService.getDefault()
    can create N instances and return to clients


org.eclipse.core.internal.resources.Workspace.open(IProgressMonitor)
    -> org.eclipse.core.internal.resources.WorkspacePreferences.WorkspacePreferences()
    -> org.eclipse.core.runtime.Plugin.getPluginPreferences()
    Deprecated, not thread safe, why we still use this and not Platform.getPreferencesService()?


Last place where I've stopped my analysys: org.eclipse.core.internal.resources.Workspace.open(IProgressMonitor)
    -> org.eclipse.core.internal.resources.Workspace.startup(IProgressMonitor)
    -> org.eclipse.core.internal.resources.SaveManager.restore(IProgressMonitor)
Comment 4 Dani Megert CLA 2017-05-10 12:35:15 EDT
(In reply to Mikaël Barbero from comment #2)
> Unfortunately I won't have time to look into it by M5. Moving to M6

Ping! Please finish for RC1.
Comment 5 Mikaël Barbero CLA 2017-05-10 13:02:14 EDT
No needed anymore, asynch init has been reverted in http://git.eclipse.org/c/platform/eclipse.platform.resources.git/commit/?id=7069f16072925b47d40a4ed8d58c1561ae6c276a