Bug 47732 - Word Extractor throws OUT OF MEMORY Java Heap Space exception
Summary: Word Extractor throws OUT OF MEMORY Java Heap Space exception
Status: RESOLVED INVALID
Alias: None
Product: POI
Classification: Unclassified
Component: POIFS (show other bugs)
Version: 3.2-FINAL
Hardware: PC Windows Server 2003
: P2 major (vote)
Target Milestone: ---
Assignee: POI Developers List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-08-25 01:35 UTC by Gitu
Modified: 2011-02-25 17:04 UTC (History)
1 user (show)



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Gitu 2009-08-25 01:35:40 UTC
Hi,

I have a word document which is nearly 30 MB in size and I need to extract the content of that. But POIFSFileSystem throws an out of memory error and is not able to open the document.

I searched on google to find some solution and found this:

They recommend to increase the amount of memory that
Java can use with these runtime options;

java -Xms<initial heap size> -Xmx<maximum heap size>

But we do not have an option to increase the same. 

I wanted to know if there is any other way in which we can get the content in chunks or so OR some other solution without modifiying the amount of java memory. 		

Many thanks in advance,
Gitu
Comment 1 Nick Burch 2011-02-25 17:04:46 UTC
You need to increase your Java heap size. The word format doesn't support incremental reading.