Bug 208936 - [index] OutOfMemoryError in Java Indexing when launching plugin as standalone application
Summary: [index] OutOfMemoryError in Java Indexing when launching plugin as standalone...
Status: VERIFIED DUPLICATE of bug 166223
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.2.2   Edit
Hardware: PC Windows XP
: P3 major (vote)
Target Milestone: 3.3.2   Edit
Assignee: Frederic Fusier CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-11-06 14:47 EST by Arieh Bibliowicz CLA
Modified: 2007-12-12 05:25 EST (History)
3 users (show)

See Also:


Attachments
jbuilder init file (117 bytes, application/octet-stream)
2007-11-06 14:47 EST, Arieh Bibliowicz CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Arieh Bibliowicz CLA 2007-11-06 14:47:43 EST
Created attachment 82254 [details]
jbuilder init file

Build ID: M20070212-1330

Steps To Reproduce:
I'm running Jbuilder 2007 which is based on eclipse 3.2.2.r322_v20070119-RQghndJN8IM0MsK (build M20070212-1330), after a number of times that my europa version of eclipse crashed while playing with GMF. 
1) I created an example plugin following the instructions in: http://www.onjava.com/pub/a/onjava/2005/02/09/eclipse.html?page=1
2) Tried to test the example (and pretty slim) plugin by clicking on "Launch an eclipse application" on the plugin.xml file, overview tab.
3) The new eclipse instance goes up, and in the console from  where the instance was called I get "Exception in thread "Java indexing" java.lang.OutOfMemoryError: Java heap space"

More information:
I reproduced this bug many times. I had no time to try to reproduce it in the europa eclipse version, but I am also getting there a lot of eclipse crashed because of overallocation of memory.
Tried to increase the ammount of heap as explained in bug 92250 but still didn't help.
Comment 1 Arieh Bibliowicz CLA 2007-11-06 14:48:41 EST
Stack:

Exception in thread "Java indexing" java.lang.OutOfMemoryError: Java heap space
	at org.eclipse.jdt.internal.compiler.util.HashtableOfObject.<init>(HashtableOfObject.java:39)
	at org.eclipse.jdt.internal.compiler.util.HashtableOfObject.rehash(HashtableOfObject.java:139)
	at org.eclipse.jdt.internal.compiler.util.HashtableOfObject.put(HashtableOfObject.java:112)
	at org.eclipse.jdt.internal.core.index.DiskIndex.copyQueryResults(DiskIndex.java:325)
	at org.eclipse.jdt.internal.core.index.DiskIndex.mergeWith(DiskIndex.java:489)
	at org.eclipse.jdt.internal.core.index.Index.save(Index.java:178)
	at org.eclipse.jdt.internal.core.search.indexing.IndexManager.saveIndex(IndexManager.java:588)
	at org.eclipse.jdt.internal.core.search.indexing.AddJarFileToIndex.execute(AddJarFileToIndex.java:200)
	at org.eclipse.jdt.internal.core.search.processing.JobManager.run(JobManager.java:372)
	at java.lang.Thread.run(Thread.java:619)
Comment 2 Tod Creasey CLA 2007-11-07 08:36:34 EST
If you enable the heap monitor (on the general page) you can get an idea of how big what you are running is. 

What else do you have installed beside the SDK?

The OutOfMemory error is happening in JDT Core. I have seen this myself during Java Indexing now and again
Comment 3 Frederic Fusier CLA 2007-11-07 09:17:27 EST
Definitely looks as a duplicate of 166223 which was fixed in 3.3.

However, I was not able to reproduce the OOME following the comment 0 scenario.
One thing is not clear in this scenario: JBuilder is using Eclipse 3.2.2 and you're talking about Europa version which is based on Eclipse 3.3!?

Tod, can you describe your scenario to reproduce the problem and help me to verify  that it's fixed using Eclipse 3.3? Thanks


*** This bug has been marked as a duplicate of bug 166223 ***
Comment 4 Tod Creasey CLA 2007-11-07 09:40:25 EST
Frederic I am seeing this in 3.4 but not all of the time.

STEPS
1) Load platform-ui and platform-ui-tests module from HEAD
2) Self host
3) In the self hosted workspace select Import-Existing Plug-ins
4) Select source 
5) Select ide and workbench
6) Hit finish
7) The wizard will finish and a build will kick off. At this point the build will fail.
Comment 5 Frederic Fusier CLA 2007-11-07 11:31:46 EST
(In reply to comment #4)
> Frederic I am seeing this in 3.4 but not all of the time.
> 
> STEPS
> 1) Load platform-ui and platform-ui-tests module from HEAD
> 2) Self host
> 3) In the self hosted workspace select Import-Existing Plug-ins
> 4) Select source 
> 5) Select ide and workbench
> 6) Hit finish
> 7) The wizard will finish and a build will kick off. At this point the build
> will fail.
> 
What -Xmx do use while launching your self hosted workspace?
That does not look like the same issue as the OOME occurred in indexing. IMO, you should open a new bug for this issue...
Comment 6 Tod Creasey CLA 2007-11-07 12:13:23 EST
I am using the default settings.

I'll open another bug next time I see it.
Comment 7 Frederic Fusier CLA 2007-11-07 12:38:35 EST
(In reply to comment #6)
> I am using the default settings.
> 
> I'll open another bug next time I see it.
> 
OK, thanks
Comment 8 Tod Creasey CLA 2007-11-07 12:52:36 EST
See Bug 209065 for my issue
Comment 9 Eric Jodet CLA 2007-12-12 05:25:47 EST
Verified for 3.4 M4 using build I20071211-0010