On 10/14/2016 3:35 AM, Davide Isoardi wrote:
> I have indexed more than 1 million of docs on a SolrCloud collections whit 5
> shards and 2 replicas.
> After the indexing if I try to query (many times) q=id:*&rows=0 I have
> different result for the document number founds.
> Why the result is not the same for all querys?
Assuming that you are not indexing new documents between requests, there
are two reasons for this problem:
1) You have documents with the same uniqueKey value in more than one of
your shards. This typically happens when the router on the collection
is set to "implicit" ... which basically means "manual."
2) Your two replicas are out of sync, which might have any number of causes.
Side note: "q=id:*" is a very inefficient query. You would be better
off with a range query -- "q=id:[* TO *]". That would be faster and use
less memory. If the id field is your uniqueKey, then an even faster
query and 100% equivalent query is the one for all docs -- "q=*:*".