I have had OOM, when there was too much of data being retrieved by Ibatis.
with 2000+ statements, I see that as one of the possibility. My heap was
holding up for X amount of data, and I had a hack to loop it when more than
X was there. Increasing the heap helped me too.

-Sundar

On Wed, Mar 11, 2009 at 12:41 AM, Kengkaj Sathianpantarit <
kengka...@gmail.com> wrote:

> Try to increase java heap space by using -Xmx option.
>
> Best Regards,
> Kengkaj
> email: kengkaj.s at gmail dot com
>
>
> On Tue, Mar 10, 2009 at 7:30 PM, Ben Shory <be...@sapiens.com> wrote:
>
>> Hi,
>> I have ~2000 statements spread over a few hundreds of sqlmap.xml
>> As soon as I init the SqlMapClient I get:
>>
>> Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
>>        at java.util.Arrays.copyOfRange(Arrays.java:3209)
>>        at java.lang.String.<init>(String.java:216)
>>        at
>> com.sun.org.apache.xerces.internal.xni.XMLString.toString(XMLString.java
>> :185)
>>        at
>> com.sun.org.apache.xerces.internal.impl.XMLDTDScannerImpl.scanElementDec
>> l(XMLDTDScannerImpl.java:908)
>>        at
>> com.sun.org.apache.xerces.internal.impl.XMLDTDScannerImpl.scanDecls(XMLD
>> TDScannerImpl.java:1980)
>>        at
>> com.sun.org.apache.xerces.internal.impl.XMLDTDScannerImpl.scanDTDExterna
>> lSubset(XMLDTDScannerImpl.java:320)
>>        at
>> com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$DTDDriver
>> .dispatch(XMLDocumentScannerImpl.java:1201)
>>        at
>> com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$DTDDriver
>> .next(XMLDocumentScannerImpl.java:1089)
>>        at
>> com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDri
>> ver.next(XMLDocumentScannerImpl.java:1002)
>>        at
>> com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLD
>> ocumentScannerImpl.java:648)
>>        at
>> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.s
>> canDocument(XMLDocumentFragmentScannerImpl.java:510)
>>        at
>> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML1
>> 1Configuration.java:807)
>>        at
>> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML1
>> 1Configuration.java:737)
>>        at
>> com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.jav
>> a:107)
>>        at
>> com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.jav
>> a:225)
>>        at
>> com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(Docume
>> ntBuilderImpl.java:283)
>>        at
>> com.ibatis.common.xml.NodeletParser.createDocument(NodeletParser.java:18
>> 9)
>>        at
>> com.ibatis.common.xml.NodeletParser.parse(NodeletParser.java:59)
>>        at
>> com.ibatis.sqlmap.engine.builder.xml.SqlMapParser.parse(SqlMapParser.jav
>> a:44)
>>        at
>> com.ibatis.sqlmap.engine.builder.xml.SqlMapConfigParser$10.process(SqlMa
>> pConfigParser.java:279)
>>        at
>> com.ibatis.common.xml.NodeletParser.processNodelet(NodeletParser.java:12
>> 1)
>>        at
>> com.ibatis.common.xml.NodeletParser.process(NodeletParser.java:84)
>>        at
>> com.ibatis.common.xml.NodeletParser.process(NodeletParser.java:102)
>>        at
>> com.ibatis.common.xml.NodeletParser.parse(NodeletParser.java:72)
>>        at
>> com.ibatis.common.xml.NodeletParser.parse(NodeletParser.java:60)
>>        at
>> com.ibatis.sqlmap.engine.builder.xml.SqlMapConfigParser.parse(SqlMapConf
>> igParser.java:71)
>>        at
>> com.ibatis.sqlmap.client.SqlMapClientBuilder.buildSqlMapClient(SqlMapCli
>> entBuilder.java:90)
>>        at com.sapiens.ri.util.Test.main(Test.java:24)
>>
>> Any thoughts?
>>
>> BTW I don't need all of the statements all of the time, is there some
>> kind of lazy init?
>>
>>
>

Reply via email to