On 12/13/22 15:19, Boyanapalli, Shanti wrote:
We have recently implemented Solrcloud for our Sitecore instance. We have 5
solr nodes . 2 of our solr nodes[ each have one replication only ] , are not
showing correct results. We see the below error repeated for the replications
with the issue. Can you help us figure out if there is a known issue we should
know of.
12/13/2022, 2:06:53 PM
ERROR true
x:sitecore_web_index_shard1_replica_n4
ErrorReportingConcurrentUpdateSolrClient
Error when calling SolrCmdDistributor$Req: cmd=delete{_version_=-1752137584955359232,​query=`(_group:(8cae9f6a1b7a4d08a3f789bc623a6997) AND _indexname:(sitecore_web_index))`,​commitWithin=-1}; node=StdNode:
Based on the presence of ​ in that output, looks like you copied
it out of the admin UI instead of getting it directly from solr.log.
Not a big deal, but if you look at the logfile, it will be a lot cleaner.
Based on what I can see there, it looks like sitecore is employing
deleteByQuery. Any deleteByQuery should be replaced with a two step
process that runs the query to get all the matching ID values, then
executes deleteById with those ID values.
Using deleteByQuery can cause extremely long pauses in indexing.
Imagine this fictional scenario:
Your index begins a very large segment merge at T+0 seconds. This is a
merge that's going to take two hours to finish. It might be an explicit
optimize operation, or it might be a fully automatic segment merge. An
optimize operation is more likely to have REALLY long pauses with
deleteByQuery, but it could happen with automatic merges too.
At T+30 seconds, a deleteByQuery is issued. Could be part of automated
indexing, or something that somebody initiated manually.
That delete, and any index updates that come after it, will pause for
the full time that the large index merge takes. In this fictional
scenario, that is two hours.
--
That can lead to timeout issues on your index updates. I spent several
days trying to figure out this problem when I ran into it. I think it
was Yonik that pointed out the problem to me.
I imagine that all the indexing is done by your sitecore install. If
the indexing is changed so any deleteByQuery gets replaced by the two
step process I mentioned, then this problem goes away.
Thanks,
Shawn