FAQ
Hi everyone,
I'm a newbie of Lucene, just installed it.
My problem is that the index update procedure and the searches could run
simultaneously, and, if they do, they corrupt the index file.
Is there a way to let Lucene handle this concurrency automatically (like
stop the searches till the update is finished)?
Thanks,
Stefano


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org

Search Discussions

  • Maik Schreiber at Jun 6, 2005 at 9:42 am

    My problem is that the index update procedure and the searches could run
    simultaneously, and, if they do, they corrupt the index file.
    Is there a way to let Lucene handle this concurrency automatically (like
    stop the searches till the update is finished)?
    Lucene does not handle this by itself but relies on outside synchronization.
    You might want to have a look at LuceneIndexAccessor (please see
    http://issues.apache.org/bugzilla/show_bug.cgi?id=34995)

    --
    Maik Schreiber * http://www.blizzy.de

    GPG public key: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x1F11D713
    Key fingerprint: CF19 AFCE 6E3D 5443 9599 18B5 5640 1F11 D713

    ---------------------------------------------------------------------
    To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
    For additional commands, e-mail: java-user-help@lucene.apache.org
  • Aalap Parikh at Jun 6, 2005 at 5:22 pm
    Hi,

    As per my understanding of Lucene, I think concurrent
    search and update to an index should not corrupt the
    index, given that only a single index-modifying
    operation is executing at any point of time. So in
    short, you can have multiple search operations and not
    more than one index update (add and/or delete)
    operation in progress at any time and that should not
    corrupt the index.


    Thanks,
    Aalap.

    --- Maik Schreiber
    wrote:
    My problem is that the index update procedure and
    the searches could run
    simultaneously, and, if they do, they corrupt the
    index file.
    Is there a way to let Lucene handle this
    concurrency automatically (like
    stop the searches till the update is finished)?
    Lucene does not handle this by itself but relies on
    outside synchronization.
    You might want to have a look at LuceneIndexAccessor
    (please see
    http://issues.apache.org/bugzilla/show_bug.cgi?id=34995)
    --
    Maik Schreiber * http://www.blizzy.de

    GPG public key:
    http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x1F11D713
    Key fingerprint: CF19 AFCE 6E3D 5443 9599 18B5 5640
    1F11 D713

    ---------------------------------------------------------------------
    To unsubscribe, e-mail:
    java-user-unsubscribe@lucene.apache.org
    For additional commands, e-mail:
    java-user-help@lucene.apache.org



    __________________________________
    Yahoo! Mail
    Stay connected, organized, and protected. Take the tour:
    http://tour.mail.yahoo.com/mailtour.html


    ---------------------------------------------------------------------
    To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
    For additional commands, e-mail: java-user-help@lucene.apache.org
  • Thomas Plümpe at Jun 6, 2005 at 10:43 am
    Thanks Stefano,

    well done. It's not for sure that the concurrently running
    updates and searches do corrupt the index (a full update that
    removes the files and rebuilds them can obviously do so), but
    I'm sure they'll get the point and will tell us how things like
    that are handled.

    Best,
    Thomas

    --- Ursprüngliche Nachricht ---
    Von: Stefano Buliani <stefano.buliani@fastwebnet.it>
    An: java-user@lucene.apache.org
    Betreff: searches and updates concurrency problem
    Datum: Mon, 06 Jun 2005 10:11:15 +0100

    Hi everyone,
    I'm a newbie of Lucene, just installed it.
    My problem is that the index update procedure and the searches could run
    simultaneously, and, if they do, they corrupt the index file.
    Is there a way to let Lucene handle this concurrency automatically (like
    stop the searches till the update is finished)?
    Thanks,
    Stefano


    ---------------------------------------------------------------------
    To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
    For additional commands, e-mail: java-user-help@lucene.apache.org
    --
    Geschenkt: 3 Monate GMX ProMail gratis + 3 Ausgaben stern gratis
    ++ Jetzt anmelden & testen ++ http://www.gmx.net/de/go/promail ++

    ---------------------------------------------------------------------
    To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
    For additional commands, e-mail: java-user-help@lucene.apache.org
  • Daniel Naber at Jun 6, 2005 at 6:05 pm

    On Monday 06 June 2005 11:11, Stefano Buliani wrote:

    My problem is that the index update procedure and the searches could run
    simultaneously, and, if they do, they corrupt the index file.
    Search is a read-only thing, so why should it corrupt the index? Even
    having several writers at the same time will not corrupt the index, you'll
    get an IOException because of the lock files instead.

    Regards
    Daniel

    --
    http://www.danielnaber.de

    ---------------------------------------------------------------------
    To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
    For additional commands, e-mail: java-user-help@lucene.apache.org

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupjava-user @
categorieslucene
postedJun 6, '05 at 9:24a
activeJun 6, '05 at 6:05p
posts5
users5
websitelucene.apache.org

People

Translate

site design / logo © 2022 Grokbase