hanghangliu commented on code in PR #3487:
URL: https://github.com/apache/gobblin/pull/3487#discussion_r861089078


##########
gobblin-yarn/src/main/java/org/apache/gobblin/yarn/YarnAutoScalingManager.java:
##########
@@ -217,24 +237,43 @@ void runInternal() {
 
         WorkflowConfig workflowConfig = workFlowEntry.getValue();
         JobDag jobDag = workflowConfig.getJobDag();
-
         Set<String> jobs = jobDag.getAllNodes();
 
         // sum up the number of partitions
         for (String jobName : jobs) {
           JobContext jobContext = taskDriver.getJobContext(jobName);
-
+          JobConfig jobConfig = taskDriver.getJobConfig(jobName);
+          Resource resource = 
Resource.newInstance(this.defaultContainerMemoryMbs, 
this.defaultContainerCores);
+          int numPartitions = 0;
+          String jobTag = helixInstanceTags;
           if (jobContext != null) {
             log.debug("JobContext {} num partitions {}", jobContext, 
jobContext.getPartitionSet().size());
 
             
inUseInstances.addAll(jobContext.getPartitionSet().stream().map(jobContext::getAssignedParticipant)
-                .filter(e -> e != null).collect(Collectors.toSet()));
-
-            numPartitions += jobContext.getPartitionSet().size();
+                .filter(Objects::nonNull).collect(Collectors.toSet()));
+
+            numPartitions = jobContext.getPartitionSet().size();
+            // Respect job level config for helix instance tag, specific 
resource requirement if there's any

Review Comment:
   done



-- 
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: dev-unsubscr...@gobblin.apache.org

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

Reply via email to