diff --git a/hadoop-mapreduce-project/CHANGES.txt b/hadoop-mapreduce-project/CHANGES.txt index 85a46405146..c629855634d 100644 --- a/hadoop-mapreduce-project/CHANGES.txt +++ b/hadoop-mapreduce-project/CHANGES.txt @@ -26,6 +26,9 @@ Release 2.4.0 - UNRELEASED MAPREDUCE-5670. CombineFileRecordReader should report progress when moving to the next file (Chen He via jlowe) + MAPREDUCE-5757. ConcurrentModificationException in JobControl.toList + (jlowe) + Release 2.3.1 - UNRELEASED INCOMPATIBLE CHANGES diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/jobcontrol/JobControl.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/jobcontrol/JobControl.java index 59e3331875b..2ae6d0b51e4 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/jobcontrol/JobControl.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/jobcontrol/JobControl.java @@ -77,7 +77,7 @@ public class JobControl implements Runnable { this.runnerState = ThreadState.READY; } - synchronized private static List toList( + private static List toList( LinkedList jobs) { ArrayList retv = new ArrayList(); for (ControlledJob job : jobs) { @@ -120,11 +120,11 @@ public class JobControl implements Runnable { /** * @return the jobs in the success state */ - public List getSuccessfulJobList() { + synchronized public List getSuccessfulJobList() { return toList(this.successfulJobs); } - public List getFailedJobList() { + synchronized public List getFailedJobList() { return toList(this.failedJobs); }