MAPREDUCE-2971. ant build mapreduce fails protected access jc.displayJobList (jobs) (Thomas Graves via mahadev)

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1167383 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Mahadev Konar 2011-09-09 22:42:57 +00:00
parent 146c170571
commit b982e6205f
4 changed files with 8 additions and 4 deletions

View File

@ -1265,6 +1265,9 @@ Release 0.23.0 - Unreleased
MAPREDUCE-2975. Fixed YARNRunner to use YarnConfiguration rather than MAPREDUCE-2975. Fixed YARNRunner to use YarnConfiguration rather than
Configuration. (mahadev via acmurthy) Configuration. (mahadev via acmurthy)
MAPREDUCE-2971. ant build mapreduce fails protected access jc.displayJobList
(jobs) (Thomas Graves via mahadev)
Release 0.22.0 - Unreleased Release 0.22.0 - Unreleased

View File

@ -523,7 +523,7 @@ protected void displayTasks(Job job, String type, String state)
} }
} }
protected void displayJobList(JobStatus[] jobs) public void displayJobList(JobStatus[] jobs)
throws IOException, InterruptedException { throws IOException, InterruptedException {
System.out.println("Total jobs:" + jobs.length); System.out.println("Total jobs:" + jobs.length);
System.out.println("JobId\tState\tStartTime\t" + System.out.println("JobId\tState\tStartTime\t" +

View File

@ -248,10 +248,11 @@ public JobStatus submitJob(JobID jobId, String jobSubmitDir, Credentials ts)
ApplicationReport appMaster = resMgrDelegate ApplicationReport appMaster = resMgrDelegate
.getApplicationReport(applicationId); .getApplicationReport(applicationId);
String diagnostics = (appMaster == null ? "application report is null" : appMaster.getDiagnostics());
if (appMaster == null || appMaster.getState() == ApplicationState.FAILED if (appMaster == null || appMaster.getState() == ApplicationState.FAILED
|| appMaster.getState() == ApplicationState.KILLED) { || appMaster.getState() == ApplicationState.KILLED) {
throw new IOException("Failed to run job : " + throw new IOException("Failed to run job : " +
appMaster.getDiagnostics()); diagnostics);
} }
return clientCache.getClient(jobId).getJobStatus(jobId); return clientCache.getClient(jobId).getJobStatus(jobId);
} }

View File

@ -170,10 +170,10 @@ List<JobQueueInfo> expandQueueList(JobQueueInfo[] rootQueues) {
* registered with the {@link QueueManager}. Display of the Jobs is determine * registered with the {@link QueueManager}. Display of the Jobs is determine
* by the boolean * by the boolean
* *
* @throws IOException * @throws IOException, InterruptedException
*/ */
private void displayQueueInfo(String queue, boolean showJobs) private void displayQueueInfo(String queue, boolean showJobs)
throws IOException { throws IOException, InterruptedException {
JobQueueInfo jobQueueInfo = jc.getQueueInfo(queue); JobQueueInfo jobQueueInfo = jc.getQueueInfo(queue);
if (jobQueueInfo == null) { if (jobQueueInfo == null) {