Apache9 commented on pull request #2570:
URL: https://github.com/apache/hbase/pull/2570#issuecomment-714062524


   > Do you think "fallback to primary" logic needs to be passed down from rpc 
retrying caller? Then it needs to be aware of this feature and needs to 
maintain some state. Was trying to avoid it. Yeah, this part can be optimized 
later.
   
   If you want to make a decision based on whether the previous returned 
location is stale, then you need to pass something down from the rpc retrying 
caller to the selector, as only in rpc retrying caller we can get the exception 
we want. Either by adding a parameter as I proposed above to not go to 
secondary replicas, or as your current solution, adding a stale cache in the 
selector and you need to pass down the exception and the related location.
   My concern here is that, the current 'simple' algorithm may not work well 
for some cases as my mentioned above. I suggest that we remove this part of 
code from the patch here(just do random selecting, without other consideration) 
to get this patch in quickly, and then open another issue to discuss the 
suitable algorithm, or maybe multiple algorithms.
   
   Thanks.


----------------------------------------------------------------
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.

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


Reply via email to