YARN-8205. Application State is not updated to ATS if AM launching is delayed. Contributed by Rohith Sharma K S.
This commit is contained in:
parent
7d8bcf534a
commit
1634de0fc1
@ -108,6 +108,8 @@ public void appCreated(RMApp app, long createdTime) {
|
||||
app.getApplicationSubmissionContext().getAMContainerSpec();
|
||||
entityInfo.put(ApplicationMetricsConstants.AM_CONTAINER_LAUNCH_COMMAND,
|
||||
amContainerSpec.getCommands());
|
||||
entityInfo.put(ApplicationMetricsConstants.STATE_EVENT_INFO,
|
||||
RMServerUtils.createApplicationState(app.getState()).toString());
|
||||
|
||||
entity.setOtherInfo(entityInfo);
|
||||
TimelineEvent tEvent = new TimelineEvent();
|
||||
|
@ -139,6 +139,8 @@ public void appCreated(RMApp app, long createdTime) {
|
||||
app.getApplicationSubmissionContext().getAMContainerSpec();
|
||||
entityInfo.put(ApplicationMetricsConstants.AM_CONTAINER_LAUNCH_COMMAND,
|
||||
amContainerSpec.getCommands());
|
||||
entityInfo.put(ApplicationMetricsConstants.STATE_EVENT_INFO,
|
||||
RMServerUtils.createApplicationState(app.getState()).toString());
|
||||
|
||||
entity.setInfo(entityInfo);
|
||||
TimelineEvent tEvent = new TimelineEvent();
|
||||
|
@ -541,6 +541,7 @@ private static RMApp createRMApp(ApplicationId appId) {
|
||||
when(app.getApplicationPriority()).thenReturn(Priority.newInstance(10));
|
||||
when(app.getCallerContext())
|
||||
.thenReturn(new CallerContext.Builder("context").build());
|
||||
when(app.getState()).thenReturn(RMAppState.SUBMITTED);
|
||||
return app;
|
||||
}
|
||||
|
||||
|
@ -389,6 +389,7 @@ private static RMApp createRMApp(ApplicationId appId) {
|
||||
|
||||
when(app.getApplicationSubmissionContext())
|
||||
.thenReturn(appSubmissionContext);
|
||||
when(app.getState()).thenReturn(RMAppState.SUBMITTED);
|
||||
return app;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user