Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Eclipse indexing takes forever

I have Eclipse Helios SR1 installed on my Ubuntu 10.04 desktop and I'm having to work with a huge set of web projects in it.

When I import the projects eclipse builds the workspace successfully but it keeps consuming 100% of the CPU invariably.

After checking what could be happening I found that in Eclipse's progress tab there is a couple of endless tasks:

  • System: Java indexing... n files to index
  • System: Updating JSP index
  • System: Persisting JSP translations

These tasks seem to never end and makes my Eclipse unusable.

I doubt it is a memory issue, I have 2GB in this machine and Eclipse's heap size does not get greater than 350MB and Xmx is set currently to 1024MB.

Also tried running Eclipse with different VM versions: Sun's 1.6, Sun's 1.5, and Open JDK 1.6. No changes.

I have an Athlon X2 2.2GHz processor and a 7200 rpm Samsung hard drive.

The source code is shared via SVN.

Does anyone have any idea of what could be going on?

This is my eclipse.ini just in case:

-startup
plugins/org.eclipse.equinox.launcher_1.1.0.v20100507.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.gtk.linux.x86_1.1.1.R36x_v20100810
-product
org.eclipse.epp.package.jee.product
--launcher.defaultAction
openFile
-showsplash
org.eclipse.platform
--launcher.XXMaxPermSize
256m
--launcher.defaultAction
openFile
-vmargs
-Dosgi.requiredJavaVersion=1.5
-XX:MaxPermSize=256m
-Xms40m
-Xmx1024m
-Djava.library.path=/usr/lib/jni

Thanks a lot.

like image 683
A.Sca Avatar asked Dec 01 '10 00:12

A.Sca


People also ask

What does indexer do in Eclipse?

Eclipse includes a background parser called 'Indexer' which is used to assist the developer with various kind of information, for example jumping to a variable declaration or definition. Basically it is a parser running in the background collecting information about the sources and building up that 'index' data base.


1 Answers

To fix this problem, you have to close Eclipse, delete everything in the folder:

<workspace>.metadata\.plugins\org.eclipse.dltk.core.index.sql.h2

and restart again.

And then wait a couple of mitutes for the reindexing.

like image 176
Milos Cuculovic Avatar answered Sep 23 '22 19:09

Milos Cuculovic