hadoop-mapreduce-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cdoug...@apache.org
Subject svn commit: r984687 - in /hadoop/mapreduce/trunk: CHANGES.txt src/contrib/gridmix/src/java/org/apache/hadoop/mapred/gridmix/Statistics.java
Date Thu, 12 Aug 2010 08:49:11 GMT
Author: cdouglas
Date: Thu Aug 12 08:49:11 2010
New Revision: 984687

URL: http://svn.apache.org/viewvc?rev=984687&view=rev
Log:
MAPREDUCE-1961. Fix ConcurrentModificationException in Gridmix during
shutdown. Contributed by Hong Tang

Modified:
    hadoop/mapreduce/trunk/CHANGES.txt
    hadoop/mapreduce/trunk/src/contrib/gridmix/src/java/org/apache/hadoop/mapred/gridmix/Statistics.java

Modified: hadoop/mapreduce/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/trunk/CHANGES.txt?rev=984687&r1=984686&r2=984687&view=diff
==============================================================================
--- hadoop/mapreduce/trunk/CHANGES.txt (original)
+++ hadoop/mapreduce/trunk/CHANGES.txt Thu Aug 12 08:49:11 2010
@@ -126,6 +126,9 @@ Trunk (unreleased changes)
     MAPREDUCE-1829. JobInProgress.findSpeculativeTask should use min() to
     find the candidate instead of sort(). (Scott Chen via vinodkv)
 
+    MAPREDUCE-1961. Fix ConcurrentModificationException in Gridmix during
+    shutdown. (Hong Tang via cdouglas)
+
   BUG FIXES
 
     MAPREDUCE-1845. FairScheduler.tasksToPreempt() can return negative number.

Modified: hadoop/mapreduce/trunk/src/contrib/gridmix/src/java/org/apache/hadoop/mapred/gridmix/Statistics.java
URL: http://svn.apache.org/viewvc/hadoop/mapreduce/trunk/src/contrib/gridmix/src/java/org/apache/hadoop/mapred/gridmix/Statistics.java?rev=984687&r1=984686&r2=984687&view=diff
==============================================================================
--- hadoop/mapreduce/trunk/src/contrib/gridmix/src/java/org/apache/hadoop/mapred/gridmix/Statistics.java
(original)
+++ hadoop/mapreduce/trunk/src/contrib/gridmix/src/java/org/apache/hadoop/mapred/gridmix/Statistics.java
Thu Aug 12 08:49:11 2010
@@ -30,11 +30,11 @@ import org.apache.hadoop.tools.rumen.Job
 
 import java.io.IOException;
 import java.security.PrivilegedExceptionAction;
-import java.util.ArrayList;
 import java.util.Collection;
 import java.util.List;
 import java.util.Map;
 import java.util.concurrent.ConcurrentHashMap;
+import java.util.concurrent.CopyOnWriteArrayList;
 import java.util.concurrent.CountDownLatch;
 import java.util.concurrent.TimeUnit;
 import java.util.concurrent.locks.Condition;
@@ -56,11 +56,11 @@ public class Statistics implements Compo
 
   //List of cluster status listeners.
   private final List<StatListener<ClusterStats>> clusterStatlisteners =
-    new ArrayList<StatListener<ClusterStats>>();
+    new CopyOnWriteArrayList<StatListener<ClusterStats>>();
 
   //List of job status listeners.
   private final List<StatListener<JobStats>> jobStatListeners =
-    new ArrayList<StatListener<JobStats>>();
+    new CopyOnWriteArrayList<StatListener<JobStats>>();
 
   //List of jobids and noofMaps for each job
   private static final Map<Integer, JobStats> jobMaps =



Mime
View raw message