murblanc commented on a change in pull request #1679:
URL: https://github.com/apache/lucene-solr/pull/1679#discussion_r456442024



##########
File path: solr/core/src/java/org/apache/solr/cloud/api/collections/Assign.java
##########
@@ -663,17 +553,14 @@ public AssignStrategyFactory(SolrCloudManager 
solrCloudManager) {
     public AssignStrategy create(ClusterState clusterState, DocCollection 
collection) throws IOException, InterruptedException {
       @SuppressWarnings({"unchecked", "rawtypes"})
       List<Map> ruleMaps = (List<Map>) collection.get("rule");
-      String policyName = collection.getStr(POLICY);
       @SuppressWarnings({"rawtypes"})
       List snitches = (List) collection.get(SNITCH);
 
       Strategy strategy = null;
-      if ((ruleMaps == null || ruleMaps.isEmpty()) && 
!usePolicyFramework(collection, solrCloudManager)) {
+      if ((ruleMaps == null || ruleMaps.isEmpty())) {
         strategy = Strategy.LEGACY;
       } else if (ruleMaps != null && !ruleMaps.isEmpty()) {

Review comment:
       This if clause if the opposite of the previous one, so basically it's 
just an else. I'd keep this one as the first tested and let the else pick 
LEGACY.




----------------------------------------------------------------
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.

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



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

Reply via email to