liubingxing commented on code in PR #4088:
URL: https://github.com/apache/hadoop/pull/4088#discussion_r851047073


##########
hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/retry/RetryPolicies.java:
##########
@@ -639,19 +647,24 @@ public FailoverOnNetworkExceptionRetry(RetryPolicy 
fallbackPolicy,
     
     public FailoverOnNetworkExceptionRetry(RetryPolicy fallbackPolicy,
         int maxFailovers, int maxRetries, long delayMillis, long maxDelayBase) 
{
+      this(fallbackPolicy, maxFailovers, maxRetries, delayMillis, 
maxDelayBase, 2);
+    }
+    public FailoverOnNetworkExceptionRetry(RetryPolicy fallbackPolicy,
+        int maxFailovers, int maxRetries, long delayMillis, long maxDelayBase, 
int nnSize) {
       this.fallbackPolicy = fallbackPolicy;
       this.maxFailovers = maxFailovers;
       this.maxRetries = maxRetries;
       this.delayMillis = delayMillis;
       this.maxDelayBase = maxDelayBase;
+      this.nnSize = nnSize;
     }
 
     /**
      * @return 0 if this is our first failover/retry (i.e., retry immediately),

Review Comment:
   @cndaimin I updated the code. Please take a look.



##########
hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/io/retry/RetryPolicies.java:
##########
@@ -639,19 +647,24 @@ public FailoverOnNetworkExceptionRetry(RetryPolicy 
fallbackPolicy,
     
     public FailoverOnNetworkExceptionRetry(RetryPolicy fallbackPolicy,
         int maxFailovers, int maxRetries, long delayMillis, long maxDelayBase) 
{
+      this(fallbackPolicy, maxFailovers, maxRetries, delayMillis, 
maxDelayBase, 2);
+    }
+    public FailoverOnNetworkExceptionRetry(RetryPolicy fallbackPolicy,
+        int maxFailovers, int maxRetries, long delayMillis, long maxDelayBase, 
int nnSize) {
       this.fallbackPolicy = fallbackPolicy;
       this.maxFailovers = maxFailovers;
       this.maxRetries = maxRetries;
       this.delayMillis = delayMillis;
       this.maxDelayBase = maxDelayBase;
+      this.nnSize = nnSize;
     }
 
     /**
      * @return 0 if this is our first failover/retry (i.e., retry immediately),

Review Comment:
   @cndaimin Thanks for the review. I will add the comments later.



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