lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Erick Erickson <>
Subject Re: Does Solr move documents between shards when the value of the shard key is updated ?
Date Thu, 03 Jul 2014 01:42:39 GMT
bq: Is this a BUG or a FEATURE in Solr

How about "just the way it works"?

You've changed the route key with the same
unique key, taking control of the routing.

When you change that routing, how is Solr to
know where the _old_ document lived? It would
have to, say, query the entire cluster for any doc
that had the given <uniqueKey> and delete it,
something that'd be horribly slow.

As to your follow-up question, I'm not totally sure.
I believe the delete is sent to all shards, but why
don't you test to see?


On Wed, Jul 2, 2014 at 10:22 AM, IJ <> wrote:
> So - we do end up with two copies / versions of the same document (uniqueid)
> - one in each of the two shards - Is this a BUG or a FEATURE in Solr ?
> Have a follow up question - In case one were to attempt to delete the
> document -lets say usng the CloudSolrServer - deleteById() API - would that
> attempt to delete the document in both (or all) shards ? How would Solr
> determine which shard / shards to run the delete against ?
> --
> View this message in context:
> Sent from the Solr - User mailing list archive at

View raw message