diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-router/src/main/java/org/apache/hadoop/yarn/server/router/clientrm/FederationClientInterceptor.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-router/src/main/java/org/apache/hadoop/yarn/server/router/clientrm/FederationClientInterceptor.java index 797b1aa8b7..59cd266e6f 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-router/src/main/java/org/apache/hadoop/yarn/server/router/clientrm/FederationClientInterceptor.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-router/src/main/java/org/apache/hadoop/yarn/server/router/clientrm/FederationClientInterceptor.java @@ -304,19 +304,19 @@ public GetNewApplicationResponse getNewApplication( * * Base scenarios: * - * The Client submits an application to the Router. • The Router selects one - * SubCluster to forward the request. • The Router inserts a tuple into - * StateStore with the selected SubCluster (e.g. SC1) and the appId. • The - * State Store replies with the selected SubCluster (e.g. SC1). • The Router + * The Client submits an application to the Router. The Router selects one + * SubCluster to forward the request. The Router inserts a tuple into + * StateStore with the selected SubCluster (e.g. SC1) and the appId. The + * State Store replies with the selected SubCluster (e.g. SC1). The Router * submits the request to the selected SubCluster. * * In case of State Store failure: * - * The client submits an application to the Router. • The Router selects one - * SubCluster to forward the request. • The Router inserts a tuple into State - * Store with the selected SubCluster (e.g. SC1) and the appId. • Due to the + * The client submits an application to the Router. The Router selects one + * SubCluster to forward the request. The Router inserts a tuple into State + * Store with the selected SubCluster (e.g. SC1) and the appId. Due to the * State Store down the Router times out and it will retry depending on the - * FederationFacade settings. • The Router replies to the client with an error + * FederationFacade settings. The Router replies to the client with an error * message. * * If State Store fails after inserting the tuple: identical behavior as @@ -326,26 +326,26 @@ public GetNewApplicationResponse getNewApplication( * * Scenario 1 – Crash before submission to the ResourceManager * - * The Client submits an application to the Router. • The Router selects one - * SubCluster to forward the request. • The Router inserts a tuple into State - * Store with the selected SubCluster (e.g. SC1) and the appId. • The Router - * crashes. • The Client timeouts and resubmits the application. • The Router - * selects one SubCluster to forward the request. • The Router inserts a tuple - * into State Store with the selected SubCluster (e.g. SC2) and the appId. • + * The Client submits an application to the Router. The Router selects one + * SubCluster to forward the request. The Router inserts a tuple into State + * Store with the selected SubCluster (e.g. SC1) and the appId. The Router + * crashes. The Client timeouts and resubmits the application. The Router + * selects one SubCluster to forward the request. The Router inserts a tuple + * into State Store with the selected SubCluster (e.g. SC2) and the appId. * Because the tuple is already inserted in the State Store, it returns the - * previous selected SubCluster (e.g. SC1). • The Router submits the request + * previous selected SubCluster (e.g. SC1). The Router submits the request * to the selected SubCluster (e.g. SC1). * * Scenario 2 – Crash after submission to the ResourceManager * - * • The Client submits an application to the Router. • The Router selects one - * SubCluster to forward the request. • The Router inserts a tuple into State - * Store with the selected SubCluster (e.g. SC1) and the appId. • The Router - * submits the request to the selected SubCluster. • The Router crashes. • The - * Client timeouts and resubmit the application. • The Router selects one - * SubCluster to forward the request. • The Router inserts a tuple into State - * Store with the selected SubCluster (e.g. SC2) and the appId. • The State - * Store replies with the selected SubCluster (e.g. SC1). • The Router submits + * The Client submits an application to the Router. The Router selects one + * SubCluster to forward the request. The Router inserts a tuple into State + * Store with the selected SubCluster (e.g. SC1) and the appId. The Router + * submits the request to the selected SubCluster. The Router crashes. The + * Client timeouts and resubmit the application. The Router selects one + * SubCluster to forward the request. The Router inserts a tuple into State + * Store with the selected SubCluster (e.g. SC2) and the appId. The State + * Store replies with the selected SubCluster (e.g. SC1). The Router submits * the request to the selected SubCluster (e.g. SC1). When a client re-submits * the same application to the same RM, it does not raise an exception and * replies with operation successful message. @@ -354,14 +354,14 @@ public GetNewApplicationResponse getNewApplication( * * In case of ResourceManager failure: * - * The Client submits an application to the Router. • The Router selects one - * SubCluster to forward the request. • The Router inserts a tuple into State - * Store with the selected SubCluster (e.g. SC1) and the appId. • The Router - * submits the request to the selected SubCluster. • The entire SubCluster is - * down – all the RMs in HA or the master RM is not reachable. • The Router - * times out. • The Router selects a new SubCluster to forward the request. • + * The Client submits an application to the Router. The Router selects one + * SubCluster to forward the request. The Router inserts a tuple into State + * Store with the selected SubCluster (e.g. SC1) and the appId. The Router + * submits the request to the selected SubCluster. The entire SubCluster is + * down – all the RMs in HA or the master RM is not reachable. The Router + * times out. The Router selects a new SubCluster to forward the request. * The Router update a tuple into State Store with the selected SubCluster - * (e.g. SC2) and the appId. • The State Store replies with OK answer. • The + * (e.g. SC2) and the appId. The State Store replies with OK answer. The * Router submits the request to the selected SubCluster (e.g. SC2). */ @Override diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-router/src/main/java/org/apache/hadoop/yarn/server/router/webapp/FederationInterceptorREST.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-router/src/main/java/org/apache/hadoop/yarn/server/router/webapp/FederationInterceptorREST.java index 40addc970c..8e6b1c1ee4 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-router/src/main/java/org/apache/hadoop/yarn/server/router/webapp/FederationInterceptorREST.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-router/src/main/java/org/apache/hadoop/yarn/server/router/webapp/FederationInterceptorREST.java @@ -325,19 +325,19 @@ public Response createNewApplication(HttpServletRequest hsr) *
* Base scenarios: *
- * The Client submits an application to the Router. • The Router selects one - * SubCluster to forward the request. • The Router inserts a tuple into - * StateStore with the selected SubCluster (e.g. SC1) and the appId. • The - * State Store replies with the selected SubCluster (e.g. SC1). • The Router + * The Client submits an application to the Router. The Router selects one + * SubCluster to forward the request. The Router inserts a tuple into + * StateStore with the selected SubCluster (e.g. SC1) and the appId. The + * State Store replies with the selected SubCluster (e.g. SC1). The Router * submits the request to the selected SubCluster. *
* In case of State Store failure: *
- * The client submits an application to the Router. • The Router selects one - * SubCluster to forward the request. • The Router inserts a tuple into State - * Store with the selected SubCluster (e.g. SC1) and the appId. • Due to the + * The client submits an application to the Router. The Router selects one + * SubCluster to forward the request. The Router inserts a tuple into State + * Store with the selected SubCluster (e.g. SC1) and the appId. Due to the * State Store down the Router times out and it will retry depending on the - * FederationFacade settings. • The Router replies to the client with an error + * FederationFacade settings. The Router replies to the client with an error * message. *
* If State Store fails after inserting the tuple: identical behavior as @@ -347,26 +347,26 @@ public Response createNewApplication(HttpServletRequest hsr) *
* Scenario 1 – Crash before submission to the ResourceManager *
- * The Client submits an application to the Router. • The Router selects one - * SubCluster to forward the request. • The Router inserts a tuple into State - * Store with the selected SubCluster (e.g. SC1) and the appId. • The Router - * crashes. • The Client timeouts and resubmits the application. • The Router - * selects one SubCluster to forward the request. • The Router inserts a tuple - * into State Store with the selected SubCluster (e.g. SC2) and the appId. • + * The Client submits an application to the Router. The Router selects one + * SubCluster to forward the request. The Router inserts a tuple into State + * Store with the selected SubCluster (e.g. SC1) and the appId. The Router + * crashes. The Client timeouts and resubmits the application. The Router + * selects one SubCluster to forward the request. The Router inserts a tuple + * into State Store with the selected SubCluster (e.g. SC2) and the appId. * Because the tuple is already inserted in the State Store, it returns the - * previous selected SubCluster (e.g. SC1). • The Router submits the request + * previous selected SubCluster (e.g. SC1). The Router submits the request * to the selected SubCluster (e.g. SC1). *
* Scenario 2 – Crash after submission to the ResourceManager *
- * • The Client submits an application to the Router. • The Router selects one - * SubCluster to forward the request. • The Router inserts a tuple into State - * Store with the selected SubCluster (e.g. SC1) and the appId. • The Router - * submits the request to the selected SubCluster. • The Router crashes. • The - * Client timeouts and resubmit the application. • The Router selects one - * SubCluster to forward the request. • The Router inserts a tuple into State - * Store with the selected SubCluster (e.g. SC2) and the appId. • The State - * Store replies with the selected SubCluster (e.g. SC1). • The Router submits + * The Client submits an application to the Router. The Router selects one + * SubCluster to forward the request. The Router inserts a tuple into State + * Store with the selected SubCluster (e.g. SC1) and the appId. The Router + * submits the request to the selected SubCluster. The Router crashes. The + * Client timeouts and resubmit the application. The Router selects one + * SubCluster to forward the request. The Router inserts a tuple into State + * Store with the selected SubCluster (e.g. SC2) and the appId. The State + * Store replies with the selected SubCluster (e.g. SC1). The Router submits * the request to the selected SubCluster (e.g. SC1). When a client re-submits * the same application to the same RM, it does not raise an exception and * replies with operation successful message. @@ -375,14 +375,14 @@ public Response createNewApplication(HttpServletRequest hsr) *
* In case of ResourceManager failure: *
- * The Client submits an application to the Router. • The Router selects one - * SubCluster to forward the request. • The Router inserts a tuple into State - * Store with the selected SubCluster (e.g. SC1) and the appId. • The Router - * submits the request to the selected SubCluster. • The entire SubCluster is - * down – all the RMs in HA or the master RM is not reachable. • The Router - * times out. • The Router selects a new SubCluster to forward the request. • + * The Client submits an application to the Router. The Router selects one + * SubCluster to forward the request. The Router inserts a tuple into State + * Store with the selected SubCluster (e.g. SC1) and the appId. The Router + * submits the request to the selected SubCluster. The entire SubCluster is + * down – all the RMs in HA or the master RM is not reachable. The Router + * times out. The Router selects a new SubCluster to forward the request. * The Router update a tuple into State Store with the selected SubCluster - * (e.g. SC2) and the appId. • The State Store replies with OK answer. • The + * (e.g. SC2) and the appId. The State Store replies with OK answer. The * Router submits the request to the selected SubCluster (e.g. SC2). */ @Override