Reputation: 5338
I have an Eclipse (4.4.1) working set consisting of ~60 projects (the number may be relevant, as it takes more time to refresh the workspace). Occasionally, I encounter build failures because Eclipse is unable to clean the output folder before build:
It turned out that the process which locks the file is Eclipse itself:
It also turned out that files being locked are always of XML content. Particularly, if I define resources with *.foo
extension as XML files (via Preferences -> General -> Content Types), there's a good chance they will be locked, too, once they're copied to the output path.
I thought the problem was caused by all XML resources being validated automatically:
-- so I added exclusion filters 1st and even disabled XML/XSD validation entirely. The problem stopped occurring that often, but still emerges from time to time. Refreshing or closing-reopening a project isn't helpful.
The only remedy is restarting Eclipse or running Unlocker every 1/2 hour, which is not very convenient.
Any ideas how to solve or at least further diagnose this?
Upvotes: 6
Views: 7311
Reputation: 1253
I'm not familiar with the problem, but I would tackle the problem this way:
This way, you are maybe able to pin down the Eclipse feature that causes your problem.
Upvotes: 1
Reputation: 9187
Just my 2 cents.
Perhaps you can fix this issue by following this steps:
P.S. some times i have similar problems caused by Avira Antivirus Scanner...
Upvotes: 3
Reputation: 59
I have experienced similar issues. Yes, the number of projects is probably the cause. Close the projects not in use. If that cleans things up moving groups of related project into separate work spaces should help you out.
i.e File-> Close project
Upvotes: 1
Reputation: 23921
Disable third-party version control daemons. (Like TGitCache).
They only lock resources for a short while and are not visible in Process Explorer, but are the most frequent cause of such failures.
Upvotes: 2
Reputation: 8803
Assuming that XML Validation is the main cause of your problem, I suggest you extend your search for validation points in your projects' configuration, to set off all of them:
Hope it helps.
Upvotes: 1