[ 
https://issues.apache.org/jira/browse/HDFS-9228?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15025083#comment-15025083
 ] 

Bob Hansen commented on HDFS-9228:
----------------------------------

[~James Clampffer]: Thanks for the additional comments; new patch sumbitted 
with the following changes:

bq. -needs a couple minor fixes to get rebased to the head
Rebased.

bq. -MakeRetryPolicy could return a unique_ptr to force the caller to take 
ownership. In reality this probably isn't a big deal and I'm fine with a raw 
pointer.
Good call.  More explicit this way.  Done.

bq. -The RpcEngine and RpcConnection each have their own state locks and have 
the potential to create a call cycle that deadlocks or have issues with lock 
ordering when contending with other threads. Could you add some comments about 
what calls are appropriate in what contexts? I think RpcEngine acquiring a lock 
on RpcConnection is fairly intuitive, but rules for when RpcConnection can call 
methods that acquire the engine_state_lock_ would help avoid a lot of future 
issues.
This is a tricky one.  I pulled out an interface for RpcEngine with the 
explicit contract that locks could not be acquired during any of the calls to 
the LockFreeRpcEngine interface, and refactored the code so that Requests and 
RpcConnections only get a pointer to the LockFreeRpcEngine interface.  That, 
together with the contract that locks will never be held during a callback, 
should guarantee us that these three classes are deadlock-free.

bq. -Trailing whitespace scattered around.
Fixed.

> libhdfs++ should respect NN retry configuration settings
> --------------------------------------------------------
>
>                 Key: HDFS-9228
>                 URL: https://issues.apache.org/jira/browse/HDFS-9228
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>          Components: hdfs-client
>            Reporter: Bob Hansen
>            Assignee: Bob Hansen
>         Attachments: HDFS-9228.HDFS-8707.001.patch, 
> HDFS-9228.HDFS-8707.002.patch, HDFS-9228.HDFS-8707.003.patch, 
> HDFS-9228.HDFS-8707.004.patch, HDFS-9228.HDFS-8707.005.patch, 
> HDFS-9228.HDFS-8707.006.patch
>
>
> Handle the use case of temporary network or NN hiccups and have a 
> configurable number of retries for NN operations.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to