You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@nemo.apache.org by GitBox <gi...@apache.org> on 2018/03/27 05:31:39 UTC

[GitHub] seojangho commented on a change in pull request #11: [NEMO-42] Make SchedulerRunner reactive, Ensure reverse-topological ordering in scheduling

seojangho commented on a change in pull request #11: [NEMO-42] Make SchedulerRunner reactive, Ensure reverse-topological ordering in scheduling
URL: https://github.com/apache/incubator-nemo/pull/11#discussion_r177311783
 
 

 ##########
 File path: runtime/executor/src/main/java/edu/snu/nemo/runtime/executor/MetricManagerWorker.java
 ##########
 @@ -53,7 +53,7 @@ private MetricManagerWorker(@Parameter(MetricFlushPeriod.class) final long flush
                                                       flushingPeriod, TimeUnit.MILLISECONDS);
   }
 
-  private void flushMetricMessageQueueToMaster() {
+  private synchronized void flushMetricMessageQueueToMaster() {
 
 Review comment:
   If `MetricManagerWorker#close` and `batchMetricMessages#run` happens to invoked concurrently, `flushMetricMessageQueueToMaster` would not guarantee consistent behavior without proper synchronization.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services