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 Dev (Build 201203280401) VM: Java HotSpot(TM) Client VM, 22.1-b02, Java(TM) SE Runtime Environment, 1.7.0_03-b05 OS: Windows XP User Comments: williambacchi: watching a very long string in a variable while debugging Stacktrace: java.lang.OutOfMemoryError: Java heap space at java.util.Arrays.copyOf(Arrays.java:2367) at java.lang.AbstractStringBuilder.expandCapacity(AbstractStringBuilder.java:130) at java.lang.AbstractStringBuilder.ensureCapacityInternal(AbstractStringBuilder.java:114) at java.lang.AbstractStringBuilder.append(AbstractStringBuilder.java:415) at java.lang.StringBuilder.append(StringBuilder.java:132) at org.netbeans.modules.debugger.jpda.models.AbstractVariable.getValue(AbstractVariable.java:165)
Created attachment 117737 [details] stacktrace
The heap dump is incomplete, but we can see five large Strings there, having 33.5 MB each and the reference chain. We need to improve handling of large Strings, not to load them all into the memory. Something was already done in that area, but apparently, it's not enough.
*** Bug 224572 has been marked as a duplicate of this bug. ***
Fixed by changeset: 244211:e8257225118a http://hg.netbeans.org/core-main/rev/e8257225118a
Integrated into 'main-golden', will be available in build *201301100107* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/e8257225118a User: mentlicher@netbeans.org Log: #210615: Cut the retrieved String if it's too long to limit the memory consumption.