Yes, this changed at some point. In recent releases nothing is
written to the index unless you close(), or maybe commit(), the
writer.
--
Ian.
On Thu, Feb 9, 2012 at 12:02 PM, Ganesh <emailgane@yahoo.co.in> wrote:
> Hello all,
>
> In 3.0.3 the following code works fine but in 3.5, it throws exception "No segments found".
In case of 3.0.3, Just creating writer will create files, segments.gen, segments_1 and write.lock.
In case of 3.5, only write.lock is created.
>
> Create Index Writer
> Open Reader
> Add documents
>
> I need to do this. When the application starts, I have my writer and reader ready. I
have a thread which crawls the filesytem and adds it to index and another one performs search.
Is this intentional?
>
> Regards
> Ganesh
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org
|