Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
hgromek
Contributor
Contributor

java.lang.OutOfMemoryError: Java heap space

I have been getting this error often with the past few jobs I have created. I am attempting to simply use a database input to an excel file. It seems like every time I use an advanced Excel output (updating file and not creating new file). 

 

Here's my Job (my other ones are very similar), this one only brings in 20K records. 

 

I have increased the memory for this job and enabled stream but did not fix the issue. 

 

I have attached an image of my Job - 

 

Here's the Java Error 

Starting job SpaceHeap at 11:46 26/06/2020.

[statistics] connecting to socket on port 3824
[statistics] connected
Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
at com.sun.org.apache.xerces.internal.dom.DeferredDocumentImpl.getNodeObject(Unknown Source)
at com.sun.org.apache.xerces.internal.dom.DeferredElementNSImpl.synchronizeData(Unknown Source)
at com.sun.org.apache.xerces.internal.dom.ElementNSImpl.getNamespaceURI(Unknown Source)
at org.apache.xmlbeans.impl.store.Locale.loadNode(Locale.java:1420)
at org.apache.xmlbeans.impl.store.Locale.loadNodeChildren(Locale.java:1403)
at org.apache.xmlbeans.impl.store.Locale.loadNode(Locale.java:1445)
at org.apache.xmlbeans.impl.store.Locale.loadNodeChildren(Locale.java:1403)
at org.apache.xmlbeans.impl.store.Locale.loadNode(Locale.java:1445)
at org.apache.xmlbeans.impl.store.Locale.loadNodeChildren(Locale.java:1403)
at org.apache.xmlbeans.impl.store.Locale.loadNode(Locale.java:1445)
at org.apache.xmlbeans.impl.store.Locale.parseToXmlObject(Locale.java:1385)
at org.apache.xmlbeans.impl.store.Locale.parseToXmlObject(Locale.java:1370)
at org.apache.xmlbeans.impl.schema.SchemaTypeLoaderBase.parse(SchemaTypeLoaderBase.java:370)
[statistics] disconnected
at org.apache.poi.POIXMLTypeLoader.parse(POIXMLTypeLoader.java:164)
at org.openxmlformats.schemas.spreadsheetml.x2006.main.WorksheetDocument$Factory.parse(Unknown Source)
at org.apache.poi.xssf.usermodel.XSSFSheet.read(XSSFSheet.java:226)
at org.apache.poi.xssf.usermodel.XSSFSheet.onDocumentRead(XSSFSheet.java:218)
at org.apache.poi.xssf.usermodel.XSSFWorkbook.parseSheet(XSSFWorkbook.java:443)
at org.apache.poi.xssf.usermodel.XSSFWorkbook.onDocumentRead(XSSFWorkbook.java:408)
at org.apache.poi.POIXMLDocument.load(POIXMLDocument.java:169)
at org.apache.poi.xssf.usermodel.XSSFWorkbook.<init>(XSSFWorkbook.java:300)
at de.jlo.talendcomp.excel.SpreadsheetFile.initializeWorkbook(SpreadsheetFile.java:447)
at demo.spaceheap_0_1.SpaceHeap.tFileExcelWorkbookOpen_1Process(SpaceHeap.java:1141)
at demo.spaceheap_0_1.SpaceHeap.runJobInTOS(SpaceHeap.java:2162)
at demo.spaceheap_0_1.SpaceHeap.main(SpaceHeap.java:2019)
Job SpaceHeap ended at 11:46 26/06/2020. [exit code=1]

Labels (3)
19 Replies
Anonymous
Not applicable

Hello,

As you are using a custom component tFileExcelWorkbookOpen written by talend community user, could you please let us know if this related topic helps?

https://community.talend.com/t5/Design-and-Development/resolved-tFileExcelWorkbookOpen-Error-while-i... 

We will appreciate it a lot if you could post your setting of JVM parameters screeshot here.

Best regards

Sabrina

hgromek
Contributor
Contributor
Author

Hi - It will happen if I use the standard Excel Output as well. here is a screenshot of my JVM Settings. 

  1. 0683p000009MaXc.png
hgromek
Contributor
Contributor
Author

Hi - It will happen if I use the standard Excel Output as well. here is a screenshot of my JVM Settings. 

  1. 0683p000009MaXc.png
manodwhb
Creator III
Creator III

@hgromek ,have you verified the below link? if not please and modify the parameters and see.

https://community.talend.com/t5/Migration-Configuration-and/Out-of-Memory-error-when-reading-large-E...

hgromek
Contributor
Contributor
Author

it is not an Excel Input, the input is coming from a MySQL database, the Excel is used as an output. 

hgromek
Contributor
Contributor
Author

it is not an Excel Input, the input is coming from a MySQL database, the Excel is used as an output. 

manodwhb
Creator III
Creator III

@hgromek , can you try to increase JVM and check how is it working?

manodwhb
Creator III
Creator III

@hgromek , can you try to increase JVM and check how is it working?

hgromek
Contributor
Contributor
Author

If I increase the jvm size to this the below - I get this error. 4096M can't be handled by my machine. 

0683p000009MaXr.png0683p000009MaWV.png