> In order to make a search, the mergeSegments() function must be called 
> right? Otherwise IndexSearcher won't have the most updated index files to 
> work with to do a search. I guess my point is that do I have to 
> intermittenly call Optimize or Close (to call mergeSegments()) or make 
> maybeMergeSegments to find a merge to do before using IndexSearcher? Btw, I 
> am running IndexFiles and SearchFiles at the same time.

I don't know if you have to call close() to make all modifications visible
or not.  Sounds likely.  You do not have to call optimize.  Having
one writer and one or more readers concurrently is fine.  You can
(should) call IndexReader.lastModified() to find out if the index
has been modified since the IndexReader was opened.
 
> Also, when IndexWriter.addDocument is called per file, the function calls 
> newSegmentName() to create its corresponding segement name. That segment 
> name is used to create a SegmentInfo, which gets added to the SegmentInfos 
> vector. Am I missing something?

No idea.  I'm just a lucene user and have never needed to know about
that sort of stuff.



--
Ian.
[EMAIL PROTECTED]

----------------------------------------------------------------------
Searchable personal storage and archiving from http://www.digimem.net/

--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to