% /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ %> <%@ page contentType="text/html; charset=UTF-8" import="javax.servlet.http.*" import="java.io.*" import="java.util.*" import="org.apache.hadoop.fs.*" import="org.apache.hadoop.http.HtmlQuoting" import="org.apache.hadoop.mapreduce.TaskAttemptID" import="org.apache.hadoop.mapreduce.TaskID" import="org.apache.hadoop.mapreduce.Counter" import="org.apache.hadoop.mapreduce.Counters" import="org.apache.hadoop.mapreduce.CounterGroup" import="org.apache.hadoop.mapred.*" import="org.apache.hadoop.util.*" import="java.text.*" import="org.apache.hadoop.mapreduce.jobhistory.*" import="java.security.PrivilegedExceptionAction" import="org.apache.hadoop.security.AccessControlException" import="org.apache.hadoop.mapreduce.jobhistory.JobHistoryParser.JobInfo" import="org.apache.hadoop.mapreduce.JobACL" import="org.apache.hadoop.security.authorize.AccessControlList" %> <%!private static final long serialVersionUID = 1L; %> <%! static SimpleDateFormat dateFormat = new SimpleDateFormat("d-MMM-yyyy HH:mm:ss") ; %> <% String logFile = request.getParameter("logFile"); String reasonforFailure = " "; final Path jobFile = new Path(logFile); String jobid = JobHistory.getJobIDFromHistoryFilePath(jobFile).toString(); final FileSystem fs = (FileSystem) application.getAttribute("fileSys"); final JobTracker jobTracker = (JobTracker) application.getAttribute("job.tracker"); JobInfo job = JSPUtil.checkAccessAndGetJobInfo(request, response, jobTracker, fs, jobFile); if (job == null) { return; } if (job.getJobStatus().equals("FAILED")) reasonforFailure = job.getErrorInfo(); %>
Kind | Total Tasks(successful+failed+killed) | Successful tasks | Failed tasks | Killed tasks | Start Time | Finish Time |
Setup | <%=sj.getTotalSetups()%> | <%=sj.getNumFinishedSetups()%> | <%=sj.getNumFailedSetups()%> | <%=sj.getNumKilledSetups()%> | <%=StringUtils.getFormattedTimeWithDiff(dateFormat, sj.getSetupStarted(), 0) %> | <%=StringUtils.getFormattedTimeWithDiff(dateFormat, sj.getSetupFinished(), sj.getSetupStarted()) %> |
Map | <%=sj.getTotalMaps()%> | <%=job.getFinishedMaps() %> | <%=sj.getNumFailedMaps()%> | <%=sj.getNumKilledMaps()%> | <%=StringUtils.getFormattedTimeWithDiff(dateFormat, sj.getMapStarted(), 0) %> | <%=StringUtils.getFormattedTimeWithDiff(dateFormat, sj.getMapFinished(), sj.getMapStarted()) %> |
Reduce | <%=sj.getTotalReduces()%> | <%=job.getFinishedReduces()%> | <%=sj.getNumFailedReduces()%> | <%=sj.getNumKilledReduces()%> | <%=StringUtils.getFormattedTimeWithDiff(dateFormat, sj.getReduceStarted(), 0) %> | <%=StringUtils.getFormattedTimeWithDiff(dateFormat, sj.getReduceFinished(), sj.getReduceStarted()) %> |
Cleanup | <%=sj.getTotalCleanups()%> | <%=sj.getNumFinishedCleanups()%> | <%=sj.getNumFailedCleanups()%> | <%=sj.getNumKilledCleanups()%> | <%=StringUtils.getFormattedTimeWithDiff(dateFormat, sj.getCleanupStarted(), 0) %> | <%=StringUtils.getFormattedTimeWithDiff(dateFormat, sj.getCleanupFinished(), sj.getCleanupStarted()) %> |
Counter | Map | Reduce | Total | |
---|---|---|---|---|
<%=HtmlQuoting.quoteHtmlChars(totalGroup.getDisplayName())%> | <% } %><%=HtmlQuoting.quoteHtmlChars(counter.getDisplayName())%> | <%=mapValue%> | <%=reduceValue%> | <%=totalValue%> |
Hostname | Failed Tasks |
<%=node %> | <% boolean firstId = true; for (TaskID tid : failedTasks) { if (firstId) { firstId = false; %> <%=tid %> <% } else { %> , <%=tid %> <% } } %> |
Hostname | Killed Tasks |
<%=node %> | <% boolean firstId = true; for (TaskID tid : killedTasks) { if (firstId) { firstId = false; %> <%=tid %> <% } else { %> , <%=tid %> <% } } %> |