[ https://issues.apache.org/jira/browse/MAPREDUCE-5166?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13640752#comment-13640752 ]
Sandy Ryza commented on MAPREDUCE-5166: --------------------------------------- [~acmurthy], looking at this right now and will have a patch by today. The re-use of EMPTY_COUNTERS was my first hunch when I took a look at this yesterday, but, while I agree that using new Counters() everywhere is better practice, I don't think that's what's causing the problem. EMPTY_COUNTERS is used as an operand in sums, but never summed into. 2. seems more likely to fix it. I'll post a patch that does both of these just to be safe. I ran a multi-map local job and repeatedly called getCounters on it to try to reproduce the problem, but couldn't get the exception. [~hagleitn], if I post a patch, would it be easy for you to verify it? > ConcurrentModificationException in LocalJobRunner > ------------------------------------------------- > > Key: MAPREDUCE-5166 > URL: https://issues.apache.org/jira/browse/MAPREDUCE-5166 > Project: Hadoop Map/Reduce > Issue Type: Bug > Affects Versions: 1.2.0, 2.0.4-alpha > Reporter: Gunther Hagleitner > Priority: Critical > > With the latest version hive unit tests fail in various places with the > following stack trace. The problem seems related to: MAPREDUCE-2931 > {noformat} > [junit] java.util.ConcurrentModificationException > [junit] at java.util.HashMap$HashIterator.nextEntry(HashMap.java:793) > [junit] at java.util.HashMap$ValueIterator.next(HashMap.java:822) > [junit] at > org.apache.hadoop.mapred.Counters.incrAllCounters(Counters.java:505) > [junit] at org.apache.hadoop.mapred.Counters.sum(Counters.java:528) > [junit] at > org.apache.hadoop.mapred.LocalJobRunner$Job.getCurrentCounters(LocalJobRunner.java:490) > [junit] at > org.apache.hadoop.mapred.LocalJobRunner.getJobCounters(LocalJobRunner.java:634) > [junit] at > org.apache.hadoop.mapred.JobClient$NetworkedJob.getCounters(JobClient.java:418) > [junit] at > org.apache.hadoop.hive.ql.exec.HadoopJobExecHelper$ExecDriverTaskHandle.getCounters(HadoopJobExecHelper.java:465) > [junit] at > org.apache.hadoop.hive.ql.exec.HadoopJobExecHelper.progress(HadoopJobExecHelper.java:300) > [junit] at > org.apache.hadoop.hive.ql.exec.HadoopJobExecHelper.progress(HadoopJobExecHelper.java:532) > [junit] at > org.apache.hadoop.hive.ql.exec.ExecDriver.execute(ExecDriver.java:453) > [junit] at > org.apache.hadoop.hive.ql.exec.ExecDriver.main(ExecDriver.java:681) > [junit] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > [junit] at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) > [junit] at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) > [junit] at java.lang.reflect.Method.invoke(Method.java:597) > [junit] at org.apache.hadoop.util.RunJar.main(RunJar.java:160) > {noformat} -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira