YARN-1845. Elapsed time for failed tasks that never started is wrong (Rushabh S Shah via jeagles)

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1578457 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Jonathan Turner Eagles 2014-03-17 16:50:56 +00:00
parent 96e0ca2d27
commit f8e439105c
3 changed files with 6 additions and 3 deletions

View File

@ -41,6 +41,9 @@ Release 2.5.0 - UNRELEASED
YARN-1520. update capacity scheduler docs to include necessary parameters YARN-1520. update capacity scheduler docs to include necessary parameters
(Chen He via jeagles) (Chen He via jeagles)
YARN-1845. Elapsed time for failed tasks that never started is wrong
(Rushabh S Shah via jeagles)
OPTIMIZATIONS OPTIMIZATIONS
BUG FIXES BUG FIXES

View File

@ -37,7 +37,7 @@ public static long elapsed(long started, long finished) {
} }
public static long elapsed(long started, long finished, boolean isRunning) { public static long elapsed(long started, long finished, boolean isRunning) {
if (finished > 0) { if (finished > 0 && started > 0) {
return finished - started; return finished - started;
} }
if (isRunning) { if (isRunning) {

View File

@ -75,7 +75,7 @@ jQuery.fn.dataTableExt.oApi.fnSetFilteringDelay = function ( oSettings, iDelay )
function renderHadoopDate(data, type, full) { function renderHadoopDate(data, type, full) {
if (type === 'display' || type === 'filter') { if (type === 'display' || type === 'filter') {
if(data === '0') { if(data === '0'|| data === '-1') {
return "N/A"; return "N/A";
} }
return new Date(parseInt(data)).toUTCString(); return new Date(parseInt(data)).toUTCString();