lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erick Erickson <>
Subject Re: Get replica status in solrj
Date Mon, 11 Jun 2018 15:03:21 GMT
bq. how can I get the correct replica state?

something like add this additional test.

if (reader..getClusterState().getLiveNodes().contains(replica.getNodeName())
== false) ----state is down.


On Mon, Jun 11, 2018 at 6:59 AM, Shawn Heisey <> wrote:
> On 6/11/2018 3:29 AM, y y wrote:
>> question is I can manage to get the correct replica state if I start and
>> stop solr using command line.
>>   how if solr failure or crashed, how can I get the correct replica state?
> As I have stated elsewhere on this mailing list, actual Solr crashes are
> extremely rare.  The most common reason for Solr to die suddenly is the
> intentional death that happens when OutOfMemoryError is thrown.  Other
> causes are possible, but normally indicate serious problems with the system
> itself.
> If Solr is ungracefully killed due to OOME or some other reason, then as
> Erick mentioned, live_nodes and the clusterstate will not be updated
> immediately.  Eventually, when attempts to use those replicas fail, the
> remaining Solr servers will notice that the node is down and update the
> clusterstate.  But it won't happen as soon as the node dies.
> Thanks,
> Shawn

View raw message