poi-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dpooja85 <deodhar.po...@gmail.com>
Subject Getting "java.lang.OutOfMemoryError: PermGen space" exception while reading xlsx file using POI 3.7
Date Fri, 02 Dec 2011 00:48:25 GMT
This is very intermittent problem and does *not* occur regularly.

I am reading an xlsx file using POI 3.7 and I have code as follows,

ReadOnlySharedStringsTable strings = new
ReadOnlySharedStringsTable(this.xlsxPackage);
XSSFReader xssfReader = new XSSFReader(this.xlsxPackage);
StylesTable styles = xssfReader.getStylesTable();

When I do xssfReader.getStylesTable() I get a stacktrace as follows,

Caused by: java.lang.OutOfMemoryError: PermGen space
	at java.lang.ClassLoader.defineClass1(Native Method)
	at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
	at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
	at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
	at java.net.URLClassLoader.access$000(URLClassLoader.java:56)
	at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
	at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
	at java.lang.Class.forName0(Native Method)
	at java.lang.Class.forName(Class.java:247)
	at
org.apache.xmlbeans.impl.schema.SchemaTypeImpl.getJavaImplClass(SchemaTypeImpl.java:1709)
	at
org.apache.xmlbeans.impl.schema.SchemaTypeImpl.getJavaImplConstructor(SchemaTypeImpl.java:1725)
	at
org.apache.xmlbeans.impl.schema.SchemaTypeImpl.createUnattachedNode(SchemaTypeImpl.java:1853)
	at
org.apache.xmlbeans.impl.schema.SchemaTypeImpl.createElementType(SchemaTypeImpl.java:1021)
	at
org.apache.xmlbeans.impl.values.XmlObjectBase.create_element_user(XmlObjectBase.java:893)
	at org.apache.xmlbeans.impl.store.Xobj.getUser(Xobj.java:1657)
	at
org.apache.xmlbeans.impl.store.Xobj.find_all_element_users(Xobj.java:2080)
	at
org.openxmlformats.schemas.spreadsheetml.x2006.main.impl.CTCellXfsImpl.getXfArray(Unknown
Source)
	at org.apache.poi.xssf.model.StylesTable.readFrom(StylesTable.java:148)
	at org.apache.poi.xssf.model.StylesTable.<init>(StylesTable.java:92)
	at
org.apache.poi.xssf.eventusermodel.XSSFReader.getStylesTable(XSSFReader.java:84)
	at
ariba.collaborate.spreadsheet.basic.ExcelReaderXSSF.process(ExcelReaderXSSF.java:172)

I tried searching for this on forums and on Google but did not come across
anyone who has run into this. Does anyone know why I got this and how I
should proceed with a resolution?

Thanks.


--
View this message in context: http://apache-poi.1045710.n5.nabble.com/Getting-java-lang-OutOfMemoryError-PermGen-space-exception-while-reading-xlsx-file-using-POI-3-7-tp5040315p5040315.html
Sent from the POI - User mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@poi.apache.org
For additional commands, e-mail: user-help@poi.apache.org


Mime
View raw message