sanha commented on a change in pull request #1: [NEMO-26] Implement 
SourceLocationAwareSchedulingPolicy
URL: https://github.com/apache/incubator-nemo/pull/1#discussion_r173042154
 
 

 ##########
 File path: 
runtime/master/src/main/java/edu/snu/nemo/runtime/master/scheduler/SourceLocationAwareSchedulingPolicy.java
 ##########
 @@ -46,7 +50,14 @@
   private final ExecutorRegistry executorRegistry;
   private final RoundRobinSchedulingPolicy roundRobinSchedulingPolicy;
   private final long scheduleTimeoutMs;
+  private final Lock lock = new ReentrantLock();
+  private final Condition moreExecutorsAvailableCondition = 
lock.newCondition();
 
 Review comment:
   Don't we have to share this lock and condition with 
`RoundRobinSchedulingPolicy`?
   Because this policy fall-back to the RRPolicy when it fails to find any 
source vertex or it's location, some `ScheduledTaskGroup`s can wait for the 
condition in the RRPolicy. In this case, signaling to this condition will not 
awake these `ScheduledTaskGroup`s.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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


With regards,
Apache Git Services

Reply via email to