lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jason Wu <>
Subject Re: Making lucene indexing multi threaded
Date Mon, 27 Oct 2014 16:05:51 GMT
Hi Gary,

Thanks for your response. I only call the commit when all my docs are added.

Here is the procedure of my Lucene indexing and re-indexing: 

   1. If index data exists inside index directory, remove all the index 
   2. Create IndexWriter with 256MB RAMBUFFERSIZE
   3. Process DB result set 
   - When I loop the result set, I reuse the same Document instance. 
      - At the end of each loop, I call indexWriter.addDocument(doc) 
   4. After all docs are added, call IndexWriter.commit() 
   5. IndexWriter.close(); 

Thank you,

View this message in context:
Sent from the Lucene - Java Users mailing list archive at

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message