`

关于java.lang.OutOfMemoryError: nativeGetNewTLA

阅读更多

参考http://www.blogjava.net/amigoxie/archive/2007/02/11/99330.html

Caused by: java.lang.OutOfMemoryError: nativeGetNewTLA
    at oracle.sql.NUMBER.toString(NUMBER.java:810)
    at oracle.jdbc.driver.NumberCommonAccessor.getString(NumberCommonAccessor.java:3047)
    at oracle.jdbc.driver.T4CNumberAccessor.getString(T4CNumberAccessor.java:74)
    at oracle.jdbc.driver.OracleResultSetImpl.getString(OracleResultSetImpl.java:971)
    at oracle.jdbc.driver.OracleResultSet.getString(OracleResultSet.java:494)
    at org.apache.commons.dbcp.DelegatingResultSet.getString(DelegatingResultSet.java:225)
    at org.hibernate.type.StringType.get(StringType.java:18)
    at org.hibernate.type.NullableType.nullSafeGet(NullableType.java:154)
    at org.hibernate.type.AbstractType.hydrate(AbstractType.java:81)
    at org.hibernate.persister.entity.AbstractEntityPersister.hydrate(AbstractEntityPersister.java:2096)
    at org.hibernate.loader.Loader.getRow(Loader.java:1206)
    at org.hibernate.hql.classic.QueryTranslatorImpl.list(QueryTranslatorImpl.java:912)
    at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1121)
    at org.hibernate.impl.QueryImpl.list(QueryImpl.java:79)
    at org.springframework.orm.hibernate3.HibernateTemplate$30.doInHibernate(HibernateTemplate.java:930)
    at com.cabletech.virtualpanorama.service.EquipmentHotSpotService.scriptVar(EquipmentHotSpotService.java:384)
    at com.cabletech.virtualpanorama.service.BuildApplet4Html.createJsVar(BuildApplet4Html.java:191)
    at com.cabletech.virtualpanorama.service.BuildApplet4Html.getApplet(BuildApplet4Html.java:65)
    at com.cabletech.virtualpanorama.service.DisplayService.performGetApplet(DisplayService.java:121)
    ... 119 more

一般内存无法是两类一类是程序的问题,一类是设置的问题;具体是哪一类问题还要看错误的提示。那上面的错误基本上属于第一类,因为EquipmentHotSpot表的数据量很大(),一次性查出所有的记录肯定会有问题。这是当初写代码的时候没有考虑到的。只能进行代码优化解决。当然也可以通过增加内存来解决,当这不是长远之计。如果数据继续增加到移动程度还是会出现这样的问题。

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics