Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 267697 Details for
Bug 511793
Deadlock DependencyGraphImpl and ComponentCore
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Proposed fix
511793-Avoid-deadlock-between-DependencyGraphImpl-an.patch (text/plain), 2.42 KB, created by
Aurelien Pupier
on 2017-04-07 09:09:35 EDT
(
hide
)
Description:
Proposed fix
Filename:
MIME Type:
Creator:
Aurelien Pupier
Created:
2017-04-07 09:09:35 EDT
Size:
2.42 KB
patch
obsolete
>diff --git a/plugins/org.eclipse.wst.common.modulecore/modulecore-src/org/eclipse/wst/common/componentcore/internal/util/ComponentImplManager.java b/plugins/org.eclipse.wst.common.modulecore/modulecore-src/org/eclipse/wst/common/componentcore/internal/util/ComponentImplManager.java >index 422e468..f657ce9 100644 >--- a/plugins/org.eclipse.wst.common.modulecore/modulecore-src/org/eclipse/wst/common/componentcore/internal/util/ComponentImplManager.java >+++ b/plugins/org.eclipse.wst.common.modulecore/modulecore-src/org/eclipse/wst/common/componentcore/internal/util/ComponentImplManager.java >@@ -18,6 +18,7 @@ > import java.util.Iterator; > import java.util.Map; > import java.util.Set; >+ > import org.eclipse.core.resources.IProject; > import org.eclipse.core.resources.IResourceDelta; > import org.eclipse.core.runtime.IConfigurationElement; >@@ -202,24 +203,26 @@ > } > > public IVirtualComponent createComponent(IProject project) { >- IVirtualComponent retVal = null; >- // acquire the lock that StructureEdit will need already, to prevent others from locking that before calling createComponent() - see bug 508685 >+ return createComponent(project, true); >+ } >+ >+ public synchronized IVirtualComponent createComponent(IProject project, boolean checkSettings) { > ILock lock = EMFWorkbenchEditContextFactory.getProjectLockObject(project); > try{ > if(null != lock){ > lock.acquire(); > } >- retVal = createComponent(project, true); >+ return createComponentWithoutLock(project, checkSettings); > } finally{ > if(null != lock){ > lock.release(); > } > } >- return retVal; > } > >- public synchronized IVirtualComponent createComponent(IProject project, boolean checkSettings) { >+ private IVirtualComponent createComponentWithoutLock(IProject project, boolean checkSettings) { > try { >+ > IVirtualComponent component = ComponentCacheManager.instance().getComponent(project); > if(component != null) { > return component; >@@ -248,11 +251,9 @@ > } > } > IVirtualComponent component = new VirtualComponent(project, new Path("/")); //$NON-NLS-1$ >- if(component != null) { >- ComponentCacheManager.instance().setComponentImplFactory(project, null); >- ComponentCacheManager.instance().setComponent(project, component); >- registerListener(project); >- } >+ ComponentCacheManager.instance().setComponentImplFactory(project, null); >+ ComponentCacheManager.instance().setComponent(project, component); >+ registerListener(project); > > return component; > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
apupier
:
review+
ccc
:
review-
Actions:
View
|
Diff
Attachments on
bug 511793
:
267682
|
267697
|
267761
|
267762
|
267776
|
267792