lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Daniel Collins (JIRA)" <>
Subject [jira] [Commented] (SOLR-5209) cores/action=UNLOAD of last replica removes shard from clusterstate
Date Tue, 03 Sep 2013 08:26:51 GMT


Daniel Collins commented on SOLR-5209:

When I had a look at that code, I was confused why removeCore was even attempting to remove
"all empty pre allocated slices"?  And it also tries to clean up collections, given we have
the collections API to do that, why is a simple core unload going any further?  I can see
that its "nice" and saves the user having to run the collections API to remove the collection,
but isn't it potentially dangerous (like in this case) if we are second guessing what the
user will do next?

Say they are just removing all the replicas, and re-assigning them to different hosts?  They
may want to leave the collection/shard ranges "empty" and then move the data to new hosts,
and restart the cores to re-register them.  Yes, we could/should start the new ones before
removing the old, but that's not enforced?
> cores/action=UNLOAD of last replica removes shard from clusterstate
> -------------------------------------------------------------------
>                 Key: SOLR-5209
>                 URL:
>             Project: Solr
>          Issue Type: Bug
>          Components: SolrCloud
>    Affects Versions: 4.4
>            Reporter: Christine Poerschke
>         Attachments: SOLR-5209.patch
> The problem we saw was that unloading of an only replica of a shard deleted that shard's
info from the clusterstate. Once it was gone then there was no easy way to re-create the shard
(other than dropping and re-creating the whole collection's state).
> This seems like a bug?
> around line 600 has a comment and commented out code:
> // TODO TODO TODO!!! if there are no replicas left for the slice, and the slice has no
hash range, remove it
> // if (newReplicas.size() == 0 && slice.getRange() == null) {
> // if there are no replicas left for the slice remove it

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message