You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by ma...@apache.org on 2020/09/02 18:11:58 UTC

[lucene-solr] 01/11: @703 TODO: We can do a better really fast default assign strategy that doesn't touch zk or some external system.

This is an automated email from the ASF dual-hosted git repository.

markrmiller pushed a commit to branch reference_impl
in repository https://gitbox.apache.org/repos/asf/lucene-solr.git

commit 3ffe6110d126dd22e322c86521984d2afa8823cc
Author: markrmiller@gmail.com <ma...@gmail.com>
AuthorDate: Wed Sep 2 09:09:59 2020 -0500

    @703 TODO: We can do a better really fast default assign strategy that doesn't touch zk or some external system.
---
 solr/core/src/java/org/apache/solr/cloud/api/collections/Assign.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/solr/core/src/java/org/apache/solr/cloud/api/collections/Assign.java b/solr/core/src/java/org/apache/solr/cloud/api/collections/Assign.java
index 294eb67..5171306 100644
--- a/solr/core/src/java/org/apache/solr/cloud/api/collections/Assign.java
+++ b/solr/core/src/java/org/apache/solr/cloud/api/collections/Assign.java
@@ -128,7 +128,7 @@ public class Assign {
     if (collection.getSlice(shard) != null && collection.getSlice(shard).getReplicas().isEmpty()) {
       return REPLICA_CNT.incrementAndGet();
     } else {
-      defaultValue = collection.getReplicas().size() + REPLICA_CNT.incrementAndGet();
+      defaultValue = collection.getReplicas().size() + REPLICA_CNT.incrementAndGet() * 2;
     }
 
     return defaultValue;