FAQ
HI all.

i am newbie to lucene

Do lucene provides any way to do indexing ,searching and deleting simultaneously ..

I hope we could do searching and indexing which means there can be multiple indexreader and only one indexwriter accessing the index..

Could we have two indexwriter working simultaneously...?

Any help is greatly appreciated
Thanks in advance.

regards
-Hussain

Search Discussions

  • Ramana Jelda at Jan 5, 2006 at 3:08 pm
    Hi,
    You are right. There can be multiple indexreaders but only one indexwriter
    is advised.

    No, we can not use two indexwriters simultaneously.

    Jelda

    -----Original Message-----
    From: K.A.Hussain Ali
    Sent: Thursday, April 06, 2006 5:01 PM
    To: java-user@lucene.apache.org
    Subject: searching and indexing simultaneously...

    HI all.

    i am newbie to lucene

    Do lucene provides any way to do indexing ,searching and deleting
    simultaneously ..

    I hope we could do searching and indexing which means there can be multiple
    indexreader and only one indexwriter accessing the index..

    Could we have two indexwriter working simultaneously...?

    Any help is greatly appreciated
    Thanks in advance.

    regards
    -Hussain



    ---------------------------------------------------------------------
    To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
    For additional commands, e-mail: java-user-help@lucene.apache.org
  • John Powers at Jan 5, 2006 at 3:10 pm
    But its best to only have one reader/searcher, correct?

    -----Original Message-----
    From: Ramana Jelda
    Sent: Thursday, January 05, 2006 9:08 AM
    To: java-user@lucene.apache.org
    Subject: RE: searching and indexing simultaneously...


    Hi,
    You are right. There can be multiple indexreaders but only one
    indexwriter
    is advised.

    No, we can not use two indexwriters simultaneously.

    Jelda

    -----Original Message-----
    From: K.A.Hussain Ali
    Sent: Thursday, April 06, 2006 5:01 PM
    To: java-user@lucene.apache.org
    Subject: searching and indexing simultaneously...

    HI all.

    i am newbie to lucene

    Do lucene provides any way to do indexing ,searching and deleting
    simultaneously ..

    I hope we could do searching and indexing which means there can be
    multiple
    indexreader and only one indexwriter accessing the index..

    Could we have two indexwriter working simultaneously...?

    Any help is greatly appreciated
    Thanks in advance.

    regards
    -Hussain



    ---------------------------------------------------------------------
    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
  • Vanlerberghe, Luc at Jan 5, 2006 at 4:11 pm
    One reader/searcher per server.

    My configuration uses
    - one Lucene index in a shared location,
    - one server that uses either a single IndexReader or a single
    IndexWriter to delete or add documents
    - several servers that read/search the index.

    The 'search' servers each have a single IndexReader open to handle all
    requests.
    At fixed intervals, they check the version of the index to know if it's
    time to close and reopen the IndexReader instance. (I make use of the
    DelayCloseIndexReader I contributed in
    http://issues.apache.org/jira/browse/LUCENE-445 to make sure the
    previous instance doesn't close while other threads are still using it)

    You have to make sure all servers put their lock files in a shared
    location, but from then on everything works fine...
    There was an issue with getCurrentVersion() and isCurrent() not using
    the locks properly (http://issues.apache.org/jira/browse/LUCENE-481),
    but that's resolved now (the patch is easy to backport to Lucene 1.4.3)

    Luc

    -----Original Message-----
    From: John Powers
    Sent: donderdag 5 januari 2006 16:08
    To: java-user@lucene.apache.org
    Subject: RE: searching and indexing simultaneously...

    But its best to only have one reader/searcher, correct?

    -----Original Message-----
    From: Ramana Jelda
    Sent: Thursday, January 05, 2006 9:08 AM
    To: java-user@lucene.apache.org
    Subject: RE: searching and indexing simultaneously...


    Hi,
    You are right. There can be multiple indexreaders but only one
    indexwriter
    is advised.

    No, we can not use two indexwriters simultaneously.

    Jelda

    -----Original Message-----
    From: K.A.Hussain Ali
    Sent: Thursday, April 06, 2006 5:01 PM
    To: java-user@lucene.apache.org
    Subject: searching and indexing simultaneously...

    HI all.

    i am newbie to lucene

    Do lucene provides any way to do indexing ,searching and deleting
    simultaneously ..

    I hope we could do searching and indexing which means there can be
    multiple
    indexreader and only one indexwriter accessing the index..

    Could we have two indexwriter working simultaneously...?

    Any help is greatly appreciated
    Thanks in advance.

    regards
    -Hussain



    ---------------------------------------------------------------------
    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



    ---------------------------------------------------------------------
    To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
    For additional commands, e-mail: java-user-help@lucene.apache.org
  • Ramana Jelda at Jan 5, 2006 at 4:42 pm
    Nice contribution by Luc.

    Thanks,
    Jelda

    -----Original Message-----
    From: Vanlerberghe, Luc
    Sent: Thursday, January 05, 2006 5:11 PM
    To: java-user@lucene.apache.org
    Subject: RE: searching and indexing simultaneously...

    One reader/searcher per server.

    My configuration uses
    - one Lucene index in a shared location,
    - one server that uses either a single IndexReader or a single IndexWriter
    to delete or add documents
    - several servers that read/search the index.

    The 'search' servers each have a single IndexReader open to handle all
    requests.
    At fixed intervals, they check the version of the index to know if it's time
    to close and reopen the IndexReader instance. (I make use of the
    DelayCloseIndexReader I contributed in
    http://issues.apache.org/jira/browse/LUCENE-445 to make sure the previous
    instance doesn't close while other threads are still using it)

    You have to make sure all servers put their lock files in a shared location,
    but from then on everything works fine...
    There was an issue with getCurrentVersion() and isCurrent() not using the
    locks properly (http://issues.apache.org/jira/browse/LUCENE-481),
    but that's resolved now (the patch is easy to backport to Lucene 1.4.3)

    Luc

    -----Original Message-----
    From: John Powers
    Sent: donderdag 5 januari 2006 16:08
    To: java-user@lucene.apache.org
    Subject: RE: searching and indexing simultaneously...

    But its best to only have one reader/searcher, correct?

    -----Original Message-----
    From: Ramana Jelda
    Sent: Thursday, January 05, 2006 9:08 AM
    To: java-user@lucene.apache.org
    Subject: RE: searching and indexing simultaneously...


    Hi,
    You are right. There can be multiple indexreaders but only one indexwriter
    is advised.

    No, we can not use two indexwriters simultaneously.

    Jelda

    -----Original Message-----
    From: K.A.Hussain Ali
    Sent: Thursday, April 06, 2006 5:01 PM
    To: java-user@lucene.apache.org
    Subject: searching and indexing simultaneously...

    HI all.

    i am newbie to lucene

    Do lucene provides any way to do indexing ,searching and deleting
    simultaneously ..

    I hope we could do searching and indexing which means there can be multiple
    indexreader and only one indexwriter accessing the index..

    Could we have two indexwriter working simultaneously...?

    Any help is greatly appreciated
    Thanks in advance.

    regards
    -Hussain



    ---------------------------------------------------------------------
    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



    ---------------------------------------------------------------------
    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
  • Otis Gospodnetic at Jan 5, 2006 at 6:36 pm
    As far as I know, the best information about various Lucene concurrency rules, locks and locking is in the Lucene book (e.g. http://www.lucenebook.com/search?query=concurrency+rules ).

    The short story is: use 1 IndexSearcher. Get a new one when you detect index change. Use 1 IndexWriter. If you delete documents (via IndexReader), your IndexWriter needs to be closed, and vice versa.

    Otis

    ----- Original Message ----
    From: K.A.Hussain Ali <Hussain@photoninfotech.com>
    To: java-user@lucene.apache.org
    Sent: Thu 06 Apr 2006 11:00:34 AM EDT
    Subject: searching and indexing simultaneously...

    HI all.

    i am newbie to lucene

    Do lucene provides any way to do indexing ,searching and deleting simultaneously ..

    I hope we could do searching and indexing which means there can be multiple indexreader and only one indexwriter accessing the index..

    Could we have two indexwriter working simultaneously...?

    Any help is greatly appreciated
    Thanks in advance.

    regards
    -Hussain





    ---------------------------------------------------------------------
    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
postedJan 5, '06 at 3:00p
activeJan 5, '06 at 6:36p
posts6
users5
websitelucene.apache.org

People

Translate

site design / logo © 2022 Grokbase