use of org.apache.hadoop.yarn.api.records.ApplicationTimeoutType in project hadoop by apache.
the class ApplicationStateDataPBImpl method initApplicationTimeout.
private void initApplicationTimeout() {
if (this.applicationTimeouts != null) {
return;
}
ApplicationStateDataProtoOrBuilder p = viaProto ? proto : builder;
List<ApplicationTimeoutMapProto> lists = p.getApplicationTimeoutsList();
this.applicationTimeouts = new HashMap<ApplicationTimeoutType, Long>(lists.size());
for (ApplicationTimeoutMapProto timeoutProto : lists) {
this.applicationTimeouts.put(ProtoUtils.convertFromProtoFormat(timeoutProto.getApplicationTimeoutType()), timeoutProto.getTimeout());
}
}
use of org.apache.hadoop.yarn.api.records.ApplicationTimeoutType in project hadoop by apache.
the class RMAppLifetimeMonitor method updateApplicationTimeouts.
public void updateApplicationTimeouts(ApplicationId appId, Map<ApplicationTimeoutType, Long> timeouts) {
for (Entry<ApplicationTimeoutType, Long> entry : timeouts.entrySet()) {
ApplicationTimeoutType timeoutType = entry.getKey();
RMAppToMonitor update = new RMAppToMonitor(appId, timeoutType);
register(update, entry.getValue());
}
}
Aggregations