List of usage examples for org.apache.hadoop.yarn.api ApplicationClientProtocol getNewApplication
@Public @Stable @Idempotent public GetNewApplicationResponse getNewApplication(GetNewApplicationRequest request) throws YarnException, IOException;
The interface used by clients to obtain a new ApplicationId for submitting new applications.
The ResourceManager
responds with a new, monotonically increasing, ApplicationId which is used by the client to submit a new application.
The ResourceManager
also responds with details such as maximum resource capabilities in the cluster as specified in GetNewApplicationResponse .
From source file:org.springframework.yarn.client.ClientRmTemplate.java
License:Apache License
@Override public GetNewApplicationResponse getNewApplication() { return execute(new YarnRpcCallback<GetNewApplicationResponse, ApplicationClientProtocol>() { @Override/*w w w. java2s . co m*/ public GetNewApplicationResponse doInYarn(ApplicationClientProtocol proxy) throws YarnException, IOException { GetNewApplicationRequest request = Records.newRecord(GetNewApplicationRequest.class); return proxy.getNewApplication(request); } }); }