[ 
https://issues.apache.org/jira/browse/SOLR-8238?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17694107#comment-17694107
 ] 

David Smiley commented on SOLR-8238:
------------------------------------

{quote}The intention here ...
{quote}
I couldn't find that intention documented or commented in code either.  
"preferredLeaders" sounds like it could absolutely mean that the replica should 
be the leader if it's capable of being so at all times (e.g. at startup) just 
as we have a similar sounding feature for the Overseer.
{quote}{color:#172b4d}In the general case, the leader role imposes a small 
amount of additional work on a node that it can usually be ignored.{color}
{quote}
For NRT, I agree.  For TLOG, no; this is where indexing is exclusively 
happening.  It can be a lot of extra work.  It's also where shard splits 
happen, if you're using that.  Furthermore, with SolrJ options to query only 
leaders (or exclusively the leaders) being possible, there can be an even 
greater need to ensure that leaders are wherever you want them to be.
{quote}2> is the REBALANCELEADERS command. But this noticeably impacted 
performance in a situation where literally hundreds of replicas on a single 
Solr instance were leaders, very special circumstances.
{quote}
I could see that being an issue.  What if the node were to execute the 
rebalancing serially so as to not do too much of it at once?  This wouldn't 
block core loading; it'd be happening async after.

> Make Solr respect preferredLeader at startup
> --------------------------------------------
>
>                 Key: SOLR-8238
>                 URL: https://issues.apache.org/jira/browse/SOLR-8238
>             Project: Solr
>          Issue Type: Improvement
>          Components: SolrCloud
>    Affects Versions: 5.2.1
>            Reporter: Peter Morgan
>            Priority: Minor
>
> After setting preferredLeader property, noticed that upon restarting leaders 
> revert to wherever they were previously running before REBALANCE was called.  
>  I would expect the preferredLeader to influence the startup election, but it 
> appears it is not observed.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to