This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Build: NetBeans IDE 7.0 M2 (Build 201010151251) VM: Java HotSpot(TM) 64-Bit Server VM, 16.3-b01, Java(TM) SE Runtime Environment, 1.6.0_20-b02 OS: Windows 7 User Comments: nomood: at startup 700x23: Opened software -- Sanning projects.... GUEST: initial open nomood: just opening netbeans. It was while netbeans was scanning projects bokc: Starting NB nomood: at startup nomood: at startup Stacktrace: java.lang.OutOfMemoryError: Java heap space at java.util.Arrays.copyOf(Arrays.java:2882) at java.lang.AbstractStringBuilder.expandCapacity(AbstractStringBuilder.java:100) at java.lang.AbstractStringBuilder.append(AbstractStringBuilder.java:390) at java.lang.StringBuffer.append(StringBuffer.java:219) at org.netbeans.modules.project.ui.OpenProjectList.printMsg(OpenProjectList.java:177) at org.netbeans.modules.project.ui.OpenProjectList.log(OpenProjectList.java:162)
Created attachment 102926 [details] stacktrace
Stack trace irrelevant for diagnosis. heapdump-431835.hprof (306Mb) has a bunch of String's. org.apache.lucene.search.FieldSortedHitQueue seems to be keeping a Comparators.readerCache, though it ought to be weak; maybe a WeakHashMap value -> key error, or maybe the heap dump just does not reflect a complete GC. form.ComponentInspector.testAction.previews looks like it's holding on to some components.
GUI Builder is hardly responsible for this, form.ComponentInspector.testAction.previews holds just one instance of a previewed form, overall of just marginal size. This bug collects OOMEs from different areas, somebody should file separate bugs for the individual reports with attached heap dumps. Here's a quick analysis of the heap dumps: * heapdump-430821.hprof - over 200,000 files and lots of objects from versioning (cvs). Might be something related to FS or VCS/CVS, or just extremely large project. * heapdump-430831.hprof - 84% in char[], runs out of memory during parsing in css parser (there is a local variable ArrayList with retained size of 300MB) * heapdump-430840.hprof - looks like css parser again * heapdump-431535.hprof - 92% in char[], css parser * heapdump-430922.hprof - not heap space but PermGen, hibernate support loading some class for JDBC connection (but don't know if it is the culprit) * heapdump-431835.hprof - tens of MB in org.apache.lucene.search.FieldCache$StringIndex (commented by Jesse) * heapdump-437533.hprof - almost 90MB in char[] created when opening project during some logging (held as local variable in org.netbeans.modules.project.ui.OpenProjectList.printMsg)
Thanks for the analysis, I filed separate bugs for each of these cases - see the bugs this depends on. Changing this to an umbrella task.
It seems all the blocking issues are resolved - closing the issue.