Browse Source

HDFS-1054. remove sleep before retry for allocating a block.
(Todd Lipcon via dhruba)



git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-0.20-append@953905 13f79535-47bb-0310-9956-ffa450edef68

Dhruba Borthakur 15 years ago
parent
commit
ed3aad8cac
2 changed files with 4 additions and 8 deletions
  1. 3 0
      CHANGES.txt
  2. 1 8
      src/hdfs/org/apache/hadoop/hdfs/DFSClient.java

+ 3 - 0
CHANGES.txt

@@ -25,6 +25,9 @@ Release 0.20-append - Unreleased
     HDFS-457. Better handling of volume failure in DataNode Storage.
     (Nicolas Spiegelberg via dhruba)
 
+    HDFS-1054. remove sleep before retry for allocating a block.
+    (Todd Lipcon via dhruba)
+
   IMPROVEMENTS
 
   BUG FIXES

+ 1 - 8
src/hdfs/org/apache/hadoop/hdfs/DFSClient.java

@@ -2886,19 +2886,12 @@ public class DFSClient implements FSConstants, java.io.Closeable {
           namenode.abandonBlock(block, src, clientName);
 
           if (errorIndex < nodes.length) {
-            LOG.debug("Excluding datanode " + nodes[errorIndex]);
+            LOG.info("Excluding datanode " + nodes[errorIndex]);
             excludedNodes.add(nodes[errorIndex]);
           }
 
           // Connection failed.  Let's wait a little bit and retry
           retry = true;
-          try {
-            if (System.currentTimeMillis() - startTime > 5000) {
-              LOG.info("Waiting to find target node: " + nodes[0].getName());
-            }
-            Thread.sleep(6000);
-          } catch (InterruptedException iex) {
-          }
         }
       } while (retry && --count >= 0);