Menu

#880 memory consumption with blob coloumn

open
DB2 Plugin (17)
5
2012-12-29
2010-06-08
No

i have a table with a blob column (size 1G). Loading it and selecting the row count tab is no problem. When i select the Content Tab it first goes, but clicking on another row in the column causes a hugh memory consumption.

Normally Squirrel uses about 100MB of main memory, with this behaviour it grows up to 300mb and it does not let me control it anymore.

for further questions feel free to ask.

Discussion

  • Martin Larsson

    Martin Larsson - 2010-08-03

    I'm seeing this on MySQL as well. Actually, it uses a lot of time, memory, and then give me a Java heap space error. The table in question has a 'MEDIUMBLOB'-column, but has only 906 records in it. A suggestion would be to not extract the blob-data when querying, if that's possible.

    Here's the stacktrace:
    java.lang.RuntimeException: java.lang.OutOfMemoryError: Java heap space
    at net.sourceforge.squirrel_sql.fw.util.TaskThreadPool$MyCallback$1.run(TaskThreadPool.java:161)
    at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
    at net.sourceforge.squirrel_sql.client.Application$1.dispatchEvent(Application.java:194)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
    Caused by: java.lang.OutOfMemoryError: Java heap space
    at com.mysql.jdbc.Buffer.<init>(Buffer.java:58)
    at com.mysql.jdbc.MysqlIO.nextRow(MysqlIO.java:1452)
    at com.mysql.jdbc.MysqlIO.readSingleRowSet(MysqlIO.java:2883)
    at com.mysql.jdbc.MysqlIO.getResultSet(MysqlIO.java:476)
    at com.mysql.jdbc.MysqlIO.readResultsForQueryOrUpdate(MysqlIO.java:2576)
    at com.mysql.jdbc.MysqlIO.readAllResults(MysqlIO.java:1757)
    at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:2167)
    at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2642)
    at com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2571)
    at com.mysql.jdbc.StatementImpl.executeQuery(StatementImpl.java:1464)
    at net.sourceforge.squirrel_sql.client.session.mainpanel.objecttree.tabs.table.ContentsTab.createDataSet(ContentsTab.java:277)
    at net.sourceforge.squirrel_sql.client.session.mainpanel.objecttree.tabs.BaseDataSetTab$1.run(BaseDataSetTab.java:123)
    at net.sourceforge.squirrel_sql.fw.util.TaskExecuter.run(TaskExecuter.java:82)
    at java.lang.Thread.run(Thread.java:619)

    M.

     
  • Rob Manning

    Rob Manning - 2010-08-03

    Does the following setting help ?

    "Global Preferences" -> "Data Type Controls" : "BLOB" : "Read contents when table is first loaded" : "Read only the first 255 "

    Rob

     
  • Martin Reinfandt

    has no effect, the memory consumption is still the same

     
  • Rob Manning

    Rob Manning - 2010-08-04

    What database driver and db version are you using ?

    Rob

     
  • Martin Reinfandt

    I'm using the JDBC DB2 Driver 3.7.73 on an DB2 UDB 9.5 FP6

     
  • Nobody/Anonymous

    Had no effect for me either. I'm running mysql-connector-java-5.1.10.jar against an MySQL-version 4.0.14-nt.
    Do you want me to open this up as a separate issue?

     

Log in to post a comment.