Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » Reentrancy in WorkspaceRunnable
Reentrancy in WorkspaceRunnable [message #523720] Mon, 29 March 2010 01:11
Neil Bartlett is currently offline Neil BartlettFriend
Messages: 93
Registered: July 2009
Member
Hi, I have a problem with workspace resource locks.

My plugin defines a custom classpath container. During the call to IClasspathContainer.getClasspathEntries(), I have to call some third party code which fiddles with the file system using the java.io.File API. Fortunately I know exactly which files it changes, so I would like to call IFile.refreshLocal() to make the workspace aware of those changes.

Unfortunately, the getClasspathEntries() method is called in the context of a lock on the Project. Calling refreshLocal also tries to lock the Project, but even though I am on the same thread the lock is not reentrant, so my code hangs indefinitely waiting for itself to finish!

Is there any way to perform the refresh without obtaining a new lock?

Many thanks,
Neil
Previous Topic:Dynamic web project option is not showing in File->New->other
Next Topic:How do I stop Eclipse from worrying about everything?
Goto Forum:
  


Current Time: Fri Apr 19 21:08:59 GMT 2024

Powered by FUDForum. Page generated in 0.02680 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top