svn merge -c 1551285 FIXES: MAPREDUCE-5623. TestJobCleanup fails because of RejectedExecutionException and NPE. Contributed by Jason Lowe

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1551287 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Jason Darrell Lowe 2013-12-16 17:51:13 +00:00
parent 659cb9d9f7
commit 63cb6749bb
2 changed files with 5 additions and 5 deletions

View File

@ -100,6 +100,9 @@ Release 2.4.0 - UNRELEASED
MAPREDUCE-5656. bzip2 codec can drop records when reading data in splits MAPREDUCE-5656. bzip2 codec can drop records when reading data in splits
(jlowe) (jlowe)
MAPREDUCE-5623. TestJobCleanup fails because of RejectedExecutionException
and NPE. (jlowe)
Release 2.3.0 - UNRELEASED Release 2.3.0 - UNRELEASED
INCOMPATIBLE CHANGES INCOMPATIBLE CHANGES

View File

@ -195,8 +195,7 @@ public class TestJobCleanup {
RunningJob job = jobClient.submitJob(jc); RunningJob job = jobClient.submitJob(jc);
JobID id = job.getID(); JobID id = job.getID();
job.waitForCompletion(); job.waitForCompletion();
Counters counters = job.getCounters(); assertEquals("Job did not fail", JobStatus.FAILED, job.getJobState());
assertTrue("No. of failed maps should be 1",counters.getCounter(JobCounter.NUM_FAILED_MAPS) == 1);
if (fileName != null) { if (fileName != null) {
Path testFile = new Path(outDir, fileName); Path testFile = new Path(outDir, fileName);
@ -242,9 +241,7 @@ public class TestJobCleanup {
job.killJob(); // kill the job job.killJob(); // kill the job
job.waitForCompletion(); // wait for the job to complete job.waitForCompletion(); // wait for the job to complete
assertEquals("Job was not killed", JobStatus.KILLED, job.getJobState());
counters = job.getCounters();
assertTrue("No. of killed maps should be 1", counters.getCounter(JobCounter.NUM_KILLED_MAPS) == 1);
if (fileName != null) { if (fileName != null) {
Path testFile = new Path(outDir, fileName); Path testFile = new Path(outDir, fileName);