lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Erick Erickson" <>
Subject Re: Search Problem
Date Thu, 26 Oct 2006 16:03:14 GMT
Yes, but you must close and re-open your SEARCHER. There are various schemes
for doing this based upon now expensive it is to open a new searcher and how
often you need to do it, but it's not built into Lucene AFAIK. It all
depends upon how quickly you have to see the results of your update.

Also, be aware that your update code does not necessarily write your data to
the index immediately, so you can only be assured that the data is available
if you, say, close your index updater.


On 10/26/06, Sunil Kumar PK <> wrote:
> Hi,
> I have a program to create a lucene index, and another program for
> searching
> that index.
> The Search program create an IndexSearcher object once in its constructor,
> and I created a method doSearch to search the index. The doSearch method
> uses the indexSearcher object to get the Hits.
> My Indexer program is continuously adding documents to the index.
> My problem is that I am not getting the matching documents in my search
> results, which are added after creating the IndexSearcher object in my
> Search program.
> Is it possible to get all the matching document in the result without
> restarting the Searcher program?
> Thanks,
> Sunil

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message