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.

Bug 241142 - OutOfMemoryError: com.mysql.jdbc.ByteArrayRow uses excessive heap
Summary: OutOfMemoryError: com.mysql.jdbc.ByteArrayRow uses excessive heap
Status: RESOLVED FIXED
Alias: None
Product: db
Classification: Unclassified
Component: Show Data (show other bugs)
Version: 7.4
Hardware: All All
: P3 normal (vote)
Assignee: matthias42
URL:
Keywords:
: 241449 243450 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-01-30 00:04 UTC by kwoodle
Modified: 2015-03-15 19:14 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 207107


Attachments
stacktrace (883 bytes, text/plain)
2014-01-30 00:04 UTC, kwoodle
Details

Note You need to log in before you can comment on or make changes to this bug.
Description kwoodle 2014-01-30 00:04:25 UTC
Build: NetBeans IDE 7.4 (Build 201310111528)
VM: Java HotSpot(TM) 64-Bit Server VM, 23.21-b01, Java(TM) SE Runtime Environment, 1.7.0_21-b11
OS: Windows 7

User Comments:
kwoodle: don't remember




Stacktrace: 
java.lang.OutOfMemoryError: GC overhead limit exceeded
   at java.lang.SecurityManager.checkPackageAccess(SecurityManager.java:1528)
   at java.lang.ClassLoader$1.run(ClassLoader.java:494)
   at java.lang.ClassLoader$1.run(ClassLoader.java:492)
   at java.security.AccessController.doPrivileged(AccessController.java:0)
   at java.lang.ClassLoader.checkPackageAccess(ClassLoader.java:492)
   at org.netbeans.modules.sampler.InternalSampler.createInternalSampler(InternalSampler.java:83)
Comment 1 kwoodle 2014-01-30 00:04:30 UTC
Created attachment 144562 [details]
stacktrace
Comment 2 Tomas Hurka 2014-01-31 13:31:34 UTC
OOME is cause by processing select statement, which returns a lot of results.
Retained size of java.util.ArrayList#13700 is 750M and this ArrayList contains 2032797 instances of com.mysql.jdbc.ByteArrayRow
Comment 3 Tomas Hurka 2014-02-06 13:34:33 UTC
*** Bug 241449 has been marked as a duplicate of this bug. ***
Comment 4 matthias42 2014-10-06 21:58:54 UTC
*** Bug 243450 has been marked as a duplicate of this bug. ***
Comment 5 matthias42 2015-03-15 19:14:57 UTC
Ok - I reevaluated the "scrollable cursor support". It turns out, that the first evaluation was done with to small tables. Basicly none of the tested drivers supports big tables well when scrollable cursors are requested:

- postgresql + mysql both flood the heap (mysql can be fixed with useCursorFetch property, but it is then slow)
- derby is slow

So my advice: If you encounter problems with existing connections, check the state of "Use scrollable cursors" if checked, uncheck it and test again.

I disabled scrollable cursor support by default for now (works only for new connections):

http://hg.netbeans.org/core-main/rev/846850870fab

Please see if the above explanation helps. If so, please change the state of this bug from FIXED to VERIFIED.