提交 73ebd3e0 编写于 作者: S Stephan Ewen

Fix Java6 errors in AbstractID, pull JobManager changes into YARN app master

上级 cdee8750
......@@ -486,7 +486,7 @@ public class ApplicationMaster implements YARNClientMasterProtocol {
amStatus.setNumSlots(0);
} else {
amStatus.setNumTaskManagers(jobManager.getNumberOfTaskManagers());
amStatus.setNumSlots(jobManager.getAvailableSlots());
amStatus.setNumSlots(jobManager.getTotalNumberOfRegisteredSlots());
}
amStatus.setMessageCount(messages.size());
amStatus.setFailed(isFailed);
......
......@@ -199,8 +199,8 @@ public class AbstractID implements IOReadableWritable, Comparable<AbstractID>, j
@Override
public int compareTo(AbstractID o) {
int diff1 = Long.compare(this.upperPart, o.upperPart);
int diff2 = Long.compare(this.lowerPart, o.lowerPart);
int diff1 = (this.upperPart < o.upperPart) ? -1 : ((this.upperPart == o.upperPart) ? 0 : 1);
int diff2 = (this.lowerPart < o.lowerPart) ? -1 : ((this.lowerPart == o.lowerPart) ? 0 : 1);
return diff1 == 0 ? diff2 : diff1;
}
}
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册