giraph-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From m...@apache.org
Subject git commit: updated refs/heads/trunk to dbb021b
Date Fri, 14 Feb 2014 17:17:50 GMT
Updated Branches:
  refs/heads/trunk 62f9fd3fd -> dbb021be4


GIRAPH-853: Fix concurrency issue in GiraphMetrics (majakabiljo)


Project: http://git-wip-us.apache.org/repos/asf/giraph/repo
Commit: http://git-wip-us.apache.org/repos/asf/giraph/commit/dbb021be
Tree: http://git-wip-us.apache.org/repos/asf/giraph/tree/dbb021be
Diff: http://git-wip-us.apache.org/repos/asf/giraph/diff/dbb021be

Branch: refs/heads/trunk
Commit: dbb021be4e82dd4433ac17c8f6eecdf8b8b82919
Parents: 62f9fd3
Author: Maja Kabiljo <majakabiljo@fb.com>
Authored: Fri Feb 14 09:17:17 2014 -0800
Committer: Maja Kabiljo <majakabiljo@fb.com>
Committed: Fri Feb 14 09:17:17 2014 -0800

----------------------------------------------------------------------
 CHANGELOG                                                        | 2 ++
 .../src/main/java/org/apache/giraph/metrics/GiraphMetrics.java   | 4 ++--
 2 files changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/giraph/blob/dbb021be/CHANGELOG
----------------------------------------------------------------------
diff --git a/CHANGELOG b/CHANGELOG
index 1c8729f..c01fa83 100644
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,6 +1,8 @@
 Giraph Change Log
 
 Release 1.1.0 - unreleased
+  GIRAPH-853: Fix concurrency issue in GiraphMetrics (majakabiljo)
+
   GIRAPH-840: Upgrade to netty 4 (pavanka via majakabiljo)
 
   GIRAPH-816: ByteArrayPartition not combining vertex edges (cmuchins via majakabiljo)

http://git-wip-us.apache.org/repos/asf/giraph/blob/dbb021be/giraph-core/src/main/java/org/apache/giraph/metrics/GiraphMetrics.java
----------------------------------------------------------------------
diff --git a/giraph-core/src/main/java/org/apache/giraph/metrics/GiraphMetrics.java b/giraph-core/src/main/java/org/apache/giraph/metrics/GiraphMetrics.java
index 10a2c18..54d9604 100644
--- a/giraph-core/src/main/java/org/apache/giraph/metrics/GiraphMetrics.java
+++ b/giraph-core/src/main/java/org/apache/giraph/metrics/GiraphMetrics.java
@@ -119,7 +119,7 @@ public class GiraphMetrics {
    *
    * @param observer SuperstepObserver to watch
    */
-  public void addSuperstepResetObserver(
+  public synchronized void addSuperstepResetObserver(
       ResetSuperstepMetricsObserver observer) {
     observers.add(observer);
   }
@@ -129,7 +129,7 @@ public class GiraphMetrics {
    *
    * @param superstep long number of superstep
    */
-  public void resetSuperstepMetrics(long superstep) {
+  public synchronized void resetSuperstepMetrics(long superstep) {
     perSuperstep.setSuperstep(superstep);
     for (ResetSuperstepMetricsObserver observer : observers) {
       observer.newSuperstep(perSuperstep);


Mime
View raw message