Yarn Protocol Applicationclientprotocol

Source: Internet
Author: User

Protocol Applicationclientprotocol

Hadoop-yarn Source Reading-yarn
The agreement between the client and the ResourceManager is used to

    • Submit, Abort Job
    • Get application information, cluster metrics information, node information, queue information, and ACL information
Description of each interface:
 
   
  
  1. public getnewapplicationresponse Getnewapplication ( getnewapplicationrequest request ) throws yarnexception , ioexception

The

Client uses this method to obtain a new ApplicationID from ResourceManager to submit a new application (using the abbreviated app later). ResourceManager (later uses an abbreviated RM) responds to a value of type Getnewapplicationresponse that contains additional information such as a new, incremented ApplicationID, and the largest available resource for the cluster.  
@param: Request: To obtain the applicationrequest  of the new ApplicationID;
@ Return: The value of the Getnewapplicationrequest type that contains the ApplicationID

 
   
  
  1. public submitapplicationresponse Submitapplication ( submitapplicationrequest request ) throws yarnexception , ioexception

The

Client uses this interface to submit a new app to RM.  
clients need to provide more information, such as queues, and information about the container that starts and runs Applicationmaster, including: local resources (binaries, jars, files, etc.), security tokens, environment variables, and run commands.  
Currently, when an app is accepted, the RM responds to an (empty) submitapplicationresponse, and a deny throws an exception. The method should be called immediately after calling Getapplicationreport (Getapplicationreportrequest) to determine whether the app is properly committed.  
in Safe mode, RM checks to see if the client has access to the queue before receiving the app submission.  
@param: Request: Submit new app requests  
@return: (empty) receive the result of the submission  
@remark: When Resourcerequest exceeds the configured minimum or maximum resource boundary, An exception is thrown

 
   
  
  1. public killapplicationresponse Span style= "color: #000000;" > forcekillapplication ( request ) Span style= "color: #000000;" > throws ioexception

The

Client uses this method to abort a submitted app.   The
client specifies the app that needs to be aborted through the ApplicationID member in the parameter request.  
in Safe mode, RM checks whether the client has access to the app or queue before aborting the app.  
Currently, when the abort succeeds, the RM responds with an empty response, and when the deny aborts, RM throws an exception.  
@param: Request: Abort the requested   of the submitted app;
@return: as described above

 
   
  
  1. public getapplicationreportresponse Getapplicationreport ( getapplicationreportrequest request ) throws yarnexception , ioexception

The client uses this method to obtain an app report from the RM.
The client specifies the app to get the report by setting ApplicationID in the request.
In Safe Mode, RM checks the client for access to apps and queues before accepting app report requests.
RM responds to a value of type Getapplicationreportresponse that contains app reports for the specified app.
If the user does not have View_app permissions, the following fields are set to:

    • Tracking URL: "N/a"
    • Original tracking URL: "N/a"
    • Resource Usage Report: All-1

@param: Request for Request:app Report
@return: App Report

    
 
   
  
  1. public getclustermetricsresponse getclustermetrics( Getclustermetricsrequest Request) throws Yarnexception,ioexception;

The client uses this method to obtain the metrics (metric) of the cluster from RM.
RM responds to a Getclustermetricsresponse type value that contains Yarnclustermetrics (contains more information, such as the current number of nodes in the cluster).

 
   
  
  1. public getapplicationsresponse Span style= "color: #000000;" > getapplications ( request ) Span style= "color: #000000;" > throws ioexception

The

Client uses this method to obtain an app report that matches the request filtering criteria from RM.  
The method responds to a value of type Getapplicationsresponse. The Getapplicationsresponse type contains Applicationreport.  
If the user does not have View_app access to an app, it responds to the filtered response described by the request.

    
 
   
  
  1. public getclusternodesresponse getclusternodes( Getclusternodesrequest Request) throws Yarnexception,ioexception;

The client uses this method to obtain all node information from the RM in the cluster.

    
 
   
  
  1. Public getqueueinforesponse getqueueinfo(getqueueinforequest Request )throwsyarnexception , IOException;

The client uses this method to obtain queue information from RM.
By setting Getqueueinforequest, clients can request information like Used/total resources, sub-queues, running apps, and so on.
In Safe Mode, RM verifies that the client has access rights before responding to queue information.

    
 
   
  
  1. public getqueueuseraclsinforesponse getqueueuseracls( Getqueueuseraclsinforequest Request) throws Yarnexception,ioexception;

The client uses this method to obtain a list of queue ACLs from RM.
The RM responds to ACLs for all queues that currently exist.

 
   
  
  1. public getdelegationtokenresponse Getdelegationtoken ( getdelegationtokenrequest request ) throws yarnexception , ioexception

The

Client invokes the method to obtain an authorized token so that container can communicate with the service that uses the corresponding authorization token.   The
RM responds to an authorization token that enables the client to communicate with the corresponding service.   The
response contains a token that allows container to use and Clientrmservice (inherit Applicationclientprotocol) conversations.

    
 
   
  
  1. public renewdelegationtokenresponse renewdelegationtoken( Renewdelegationtokenrequest Request) throws Yarnexception,ioexception;

To update an existing authorization token
@param: Request: The authorization token that will be updated
@return: Expiry time for new authorization token

    
 
   
  
  1. public canceldelegationtokenresponse canceldelegationtoken( Canceldelegationtokenrequest Request) throws Yarnexception,ioexception;

Revoke an already existing authorization token.

@param: Request: The token that will be revoked
@return: Empty response

+

Yarn Protocol Applicationclientprotocol

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.