I'm pretty sure IndexSearcher does not *lock* the index, but rather waits on
the lock to be released. That lock is probably being set by the IW you have
running periodically. IS has setTimeout you can use.

As I said in a previous thread, we are moving forward to a more stable and
modern code base, so unless there's a test case and this is an issue that is
easy to resolve I'm afraid it will be in our backburner.

Sorry about the (temporary) inconvenience.

On Mon, Aug 1, 2011 at 11:09 PM, Andrew Victor <avictor...@gmail.com> wrote:

> hi,
>
> > I'm not sure I'm following what you're doing with those locks
>
> Since I'm going to "swap" the IndexSearcher pointer for a new one I
> need to make sure no other thread is currently using that pointer.
> That's why the locks are needed.
>
>
> > You can safely access one index searcher from multiple threads, but
> > IndexWriter only from one writing thread. The thread accessing IW can
> work
> > in parallel to searching threads.
>
> That part is working fine.
>
> The issue is:
>  IndexSearcher* newSearcher = new IndexSearcher("index directory")
> is blocking other IndexSearcher's.
>
>
> Regards,
>  Andrew Victor
>
>
> ------------------------------------------------------------------------------
> BlackBerry&reg; DevCon Americas, Oct. 18-20, San Francisco, CA
> The must-attend event for mobile developers. Connect with experts.
> Get tools for creating Super Apps. See the latest technologies.
> Sessions, hands-on labs, demos & much more. Register early & save!
> http://p.sf.net/sfu/rim-blackberry-1
> _______________________________________________
> CLucene-developers mailing list
> CLucene-developers@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/clucene-developers
>
>
------------------------------------------------------------------------------
BlackBerry&reg; DevCon Americas, Oct. 18-20, San Francisco, CA
The must-attend event for mobile developers. Connect with experts. 
Get tools for creating Super Apps. See the latest technologies.
Sessions, hands-on labs, demos & much more. Register early & save!
http://p.sf.net/sfu/rim-blackberry-1
_______________________________________________
CLucene-developers mailing list
CLucene-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/clucene-developers

Reply via email to