dasahcc commented on a change in pull request #883: Support enableCompression 
in workflow and job configs
URL: https://github.com/apache/helix/pull/883#discussion_r392419672
 
 

 ##########
 File path: helix-core/src/main/java/org/apache/helix/task/JobConfig.java
 ##########
 @@ -553,8 +556,11 @@ public static Builder fromMap(Map<String, String> cfg) {
       }
       if (cfg.containsKey(JobConfigProperty.RebalanceRunningTask.name())) {
         b.setRebalanceRunningTask(
-            
Boolean.valueOf(cfg.get(JobConfigProperty.RebalanceRunningTask.name())));
+            
Boolean.parseBoolean(cfg.get(JobConfigProperty.RebalanceRunningTask.name())));
       }
+      // If not set, parseBoolean returns false for null
+      b.setEnableCompression(
 
 Review comment:
   OK. The null should be final. But it make this entry explicitly in ZNRecord, 
right? Usually, our check is if the entry is not in ZNRecord, we use default 
value. But we dont carry the default value and explicitly set in ZNRecord to 
reduce the size of data set.
   
   In this case, it is better we follow our convention: do the check when we 
carry it over.

----------------------------------------------------------------
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:
[email protected]


With regards,
Apache Git Services

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

Reply via email to