OutOfMemoryException
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Laurence_Chiu
Posted On:   Tuesday, July 23, 2002 07:26 AM

Hi! I am running Lucene in Windows 2000 and I seem to get the OutofMemory Exception when indexing an 4.3 mb HTML file. The following is the exception that occurs: Exception in thread "main" java.lang.OutOfMemoryError java.io.IOException: Pipe closed at java.io.PipedReader.receive(PipedReader.java:116) at java.io.PipedReader.receive(PipedReader.java:150) at java.io.PipedWriter.write(PipedWriter.java:125) at java.io.Writer.write(Writer.java:150) at java.io.Writer.write(Writer.java:126) at org.apache.lucene.demo.html.HTMLParser.addText(HTMLParser.java) at org.apache.lucene.demo.html.HTMLParser.HTMLDocument(HTMLParser.java) at org.ap   More>>

Hi!


I am running Lucene in Windows 2000 and I seem to get the OutofMemory Exception when indexing an 4.3 mb HTML file. The following is the exception that occurs:


			
Exception in thread "main" java.lang.OutOfMemoryError
java.io.IOException: Pipe closed
at java.io.PipedReader.receive(PipedReader.java:116)
at java.io.PipedReader.receive(PipedReader.java:150)
at java.io.PipedWriter.write(PipedWriter.java:125)
at java.io.Writer.write(Writer.java:150)
at java.io.Writer.write(Writer.java:126)
at org.apache.lucene.demo.html.HTMLParser.addText(HTMLParser.java)
at org.apache.lucene.demo.html.HTMLParser.HTMLDocument(HTMLParser.java)
at org.apache.lucene.demo.html.ParserThread.run(ParserThread.java)


The memory usage tops off at 75 MB before the OutOfMemory exception occurs.


Thanks and any help would be much appreciated!


Laurence

   <<Less

Re: OutOfMemoryException

Posted By:   Otis_Gospodnetic  
Posted On:   Wednesday, July 24, 2002 08:53 AM

I don't think that's a production quality HTML parser that's included with Lucene. Try using something like NekoHTML.
In the mean time, you can java's command line options to increase the initial/maximum heap size:



-Xms set initial Java heap size
-Xmx set maximum Java heap size
About | Sitemap | Contact