lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Steiger <>
Subject Re: Best Practices for indexing in Web application
Date Tue, 02 Mar 2004 22:08:14 GMT
Otis Gospodnetic wrote:

> --- Michael Steiger <> wrote:
>>Hello Lucene Users,
>>I have a web application using Oracle as the database and I want to
>>fulltext query capablities. My idea was to extend the existing
>>update and delete methods of my backend classes to add, delete/add
>>delete respectively.
>>I'm new to Lucene and after a bit of googling and reading I found a
>>issues which I do not know how to resolve in the moment.
>>1. Concurrency of IndexWriter and IndexReader
>>It seems that it is not allowed to open an IndexWriter and an 
>>IndexReader at the same time. But if one user is changing records in
>>database (and therefore changing documents in the Lucene index) and 
>>another user is querying the index, I would need to open them both.
> This problem should be easily solvable through synchronizing on an
> object that is used as a shared lock.

Misunderstanding solved due another response. Should be no problem anymore.

>>2. Optimizing the index
>>This is maybe related to my first issue.
>>I assume that while optimizing the index no queries are allowed. How 
>>often should the index be optimized?
> Queries are allowed while an index is being optimized.
> You can optimize as often as you'd like, but the recommended approach
> is to optimize only when you know your index won't change for a while,
> or if you are running out of file descriptors.
> This is covered in at least one of the Lucene articles (links on the
> site).

thanks for your help

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

View raw message