lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Eduardo Costa Lopes <eduardo-costa.lo...@serpro.gov.br>
Subject Re: Recreating index lucene without stopping client applications
Date Wed, 11 Jul 2018 15:45:57 GMT
Hi Marco,

Basically, the content of lucene index directory is deleted and after, the index is recreated
(under the same directory). Months ago, I've researched how to "refresh" the lucene access
to get the newest data withou restarting the wep applications and, in the 6.1.0 version, it
is available the class SearchManager, which according to the documentation, should be called
its method maybeRefresh() periodically to reopen the index. Our "reopen scheduler" runs hourly
and even being executed with success it seems the data wasn't the newest.     

Thanks.


================================== 
Eduardo Costa Lopes 
SERPRO - SUPDE/DEPAE/DE009 

e-mail: eduardo-costa.lopes@serpro.gov.br 
telefone: (51) 2129 - 1180

----- Mensagem original -----
De: "Marco Reis" <marco.antonio.sousa.reis@gmail.com>
Para: "java-user" <java-user@lucene.apache.org>
Enviadas: Quarta-feira, 11 de julho de 2018 12:06:18
Assunto: Re: Recreating index lucene without stopping client applications

Hi Eduardo,

It's not clear the index recreation process, but I think you have two
different SearcherManagers, one for the app and a different one for the
command line. At some point, one of them could see the document exclusion,
and the JBoss doen't. Maybe reopen the index directory could help.




On Wed, Jul 11, 2018 at 11:46 AM Eduardo Costa Lopes <
eduardo-costa.lopes@serpro.gov.br> wrote:

> Hello,
>
> I have a Jboss application querying a lucene index to get some customer
> info. Sometimes the index are recreated while the application is running.
> Basically, the old index is erased and a new one is created. In the
> application side we have a scheduler calling
> org.apache.lucene.search.SearcherManager..maybeRefresh(), in order to get a
> new connection to the index. The issue is: today we have updated the index
> and looking for a certain name our command-line returns 4955 hits, but in
> the web app we got 4058 hits (three more). The correct hit number only is
> show if restart the jboss. I'd like to know how can we recreate the lucene
> index without need to restart the applications.
>
> Thanks in advance,
>
> Eduardo Lopes.
>
>
>
>
> -
>
>
> "Esta mensagem do SERVIÇO FEDERAL DE PROCESSAMENTO DE DADOS (SERPRO),
> empresa pública federal regida pelo disposto na Lei Federal nº 5.615, é
> enviada exclusivamente a seu destinatário e pode conter informações
> confidenciais, protegidas por sigilo profissional. Sua utilização
> desautorizada é ilegal e sujeita o infrator às penas da lei. Se você a
> recebeu indevidamente, queira, por gentileza, reenviá-la ao emitente,
> esclarecendo o equívoco."
>
> "This message from SERVIÇO FEDERAL DE PROCESSAMENTO DE DADOS (SERPRO) -- a
> government company established under Brazilian law (5.615/70) -- is
> directed exclusively to its addressee and may contain confidential data,
> protected under professional secrecy rules. Its unauthorized use is illegal
> and may subject the transgressor to the law's penalties. If you're not the
> addressee, please send it back, elucidating the failure."
>
-- 
Marco Reis
Software Engineer
http://marcoreis.net
https://github.com/masreis
+55 61 9 81194620

-


"Esta mensagem do SERVIÇO FEDERAL DE PROCESSAMENTO DE DADOS (SERPRO), empresa pública federal
regida pelo disposto na Lei Federal nº 5.615, é enviada exclusivamente a seu destinatário
e pode conter informações confidenciais, protegidas por sigilo profissional. Sua utilização
desautorizada é ilegal e sujeita o infrator às penas da lei. Se você a recebeu indevidamente,
queira, por gentileza, reenviá-la ao emitente, esclarecendo o equívoco."

"This message from SERVIÇO FEDERAL DE PROCESSAMENTO DE DADOS (SERPRO) -- a government company
established under Brazilian law (5.615/70) -- is directed exclusively to its addressee and
may contain confidential data, protected under professional secrecy rules. Its unauthorized
use is illegal and may subject the transgressor to the law's penalties. If you're not the
addressee, please send it back, elucidating the failure."

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


Mime
View raw message