pvcnt commented on code in PR #2039:
URL: https://github.com/apache/solr/pull/2039#discussion_r1410415720


##########
solr/core/src/java/org/apache/solr/cloud/api/collections/ReindexCollectionCmd.java:
##########
@@ -103,17 +104,19 @@ public class ReindexCollectionCmd implements 
CollApiCmds.CollectionApiCommand {
   public static final String STATE = "state";
   public static final String PHASE = "phase";
 
-  private static final List<String> COLLECTION_PARAMS =
-      Arrays.asList(
-          ZkStateReader.CONFIGNAME_PROP,
-          ZkStateReader.NUM_SHARDS_PROP,
-          ZkStateReader.NRT_REPLICAS,
-          ZkStateReader.PULL_REPLICAS,
-          ZkStateReader.TLOG_REPLICAS,
-          ZkStateReader.REPLICATION_FACTOR,
-          "shards",
-          CollectionAdminParams.CREATE_NODE_SET_PARAM,
-          CollectionAdminParams.CREATE_NODE_SET_SHUFFLE_PARAM);
+  private static final List<String> COLLECTION_PARAMS = makeCollectionParams();
+
+  private static List<String> makeCollectionParams() {
+    List<String> collectionParams = new ArrayList<>(10);
+    collectionParams.add(ZkStateReader.CONFIGNAME_PROP);
+    collectionParams.add(ZkStateReader.NUM_SHARDS_PROP);
+    collectionParams.add(ZkStateReader.REPLICATION_FACTOR);
+    collectionParams.add("shards");
+    collectionParams.add(CollectionAdminParams.CREATE_NODE_SET_PARAM);
+    collectionParams.add(CollectionAdminParams.CREATE_NODE_SET_SHUFFLE_PARAM);
+    collectionParams.addAll(CollectionHandlingUtils.numReplicasProperties());
+    return List.copyOf(collectionParams);

Review Comment:
   Removed that one copy as well, since it is purely internal anyway.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org
For additional commands, e-mail: issues-h...@solr.apache.org

Reply via email to