tomscut commented on pull request #3731:
URL: https://github.com/apache/hadoop/pull/3731#issuecomment-983762725


   > One doubt here: What I could decode, We try on the default namespace, if 
it fails. We do:
   > 
   > ```
   >  Set<FederationNamespaceInfo> nssWithoutFailed = getNameSpaceInfo(nss, 
nsId);
   >       return invokeOnNs(method, clazz, ioe, nssWithoutFailed);
   > ```
   > 
   > `getNameSpaceInfo(nss, nsId)` -> This returns the namespaces, removing the 
already tried namespace.
   > 
   > Then, `return invokeOnNs(method, clazz, ioe, nssWithoutFailed)` -> This 
just tries on the first namespace returned above. By the code inside the method 
`invokeOnNs`:
   > 
   > ```
   >     String nsId = nss.iterator().next().getNameserviceId();
   >     return rpcClient.invokeSingle(nsId, method, clazz);
   > ```
   > 
   > So, if the first namespace returned after excluding the default namespace 
is also down. Then we would still get an error, right? despite having other 
namespace being available? Shouldn't this be a invokeSequential kind of stuff, 
try one by one all the namespaces until you get the result. Am I missing 
something here?
   
   Thanks @ayushtkn for your comments and detailed explanation. I think you are 
right. As described on line `675` in this method, there is only one retry. And 
this PR is just to fix a bug in the current logic.
   ```
    /**
      * Invokes the method at default namespace, if default namespace is not
      * available then at the first available namespace.
      * If the namespace is unavailable, retry once with other namespace.
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: common-issues-unsubscr...@hadoop.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: common-issues-unsubscr...@hadoop.apache.org
For additional commands, e-mail: common-issues-h...@hadoop.apache.org

Reply via email to