[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.tools.pdt] Re: "Creating php model" every time Eclipse opens

I didn't mention that when I reinstalled the project, I deleted all of the xx files that Eclipse creates, including .project. I tried deleting it again, to no avail.

I ended up fixing it, and I'll post the details here in case someone has a similar problem. My project has a very large number of derived htm and xml files. These were created after my project was created, and I never refreshed the directories that contained them in Eclipse, so Eclipse did not search for them when validating the project. When my system crashed and I rebooted, something happened--either it lost the derived files, or I inadvertently told it to refresh those directories, so it started scanning for those files. I could tell from my task monitoring program what it was doing, and I didn't want it to be validating all of those files, so I killed Eclipse. I then changed the names of the containing directories by putting a . in front of them; I assumed that Eclipse would then ignore them (I'm running Windows, but Eclipse seems to ignore files/folders that begin with .). I then restarted Eclipse, let it build, and then changed the folder names back by removing the preceding dot. After this, Eclipse was still building the php model every time I started, and taking ~20 minutes, so I posted here.

Eventually I noticed in my task monitoring program that Eclipse was accessing a bunch of log files while it was building; I checked those log files and discovered Java error printouts saying it couldn't find each of the files in the directories that I thought I had hidden. That is, Eclipse *didn't* ignore the .xx directories, and when I changed their names back, it was then expecting all of the 20,000 files which were in those directories. So when I started Eclipse, it was searching for each of those files, not finding them, and then having to take the time to print a couple hundred lines of error messages to log files. This is what was consuming so much time.

The solution was for me to move the directories with all of the files out of the project folder, then allow the project to build, then refresh those directories so it was no longer expecting those folders, and then move the folders back.

The lesson for anyone encountering a similar problem: check for log files in the .metadata folder of your project directory; look for any repeated actions (such as searching for files that don't exist) and then fix that problem accordingly.

Obviously this problem is still prone to happen if I again inadvertently refresh that directory and make Eclipse aware of those files. And if that did happen, it would still take forever to build every time I start Eclipse, because it would have to validate all of those files. The real solution I need is a way to exclude specific files and directories from being inspected by Eclipse... I'll address that in another post.