From 096b4baf02d6ee975d4cc9225d69e87c2054b509 Mon Sep 17 00:00:00 2001
From: Todd Lipcon <todd@cloudera.com>
Date: Thu, 14 Jan 2010 16:05:30 -0800
Subject: [PATCH] Revert "HDFS-127: DFSClient block read failures cause open DFSInputStream to become unusable"

This reverts commit d9e9589506f8856fcb607cdf0465bad22f48a267.

This is being reverted as it causes infinite retries when there are no valid replicas.
---
 src/hdfs/org/apache/hadoop/hdfs/DFSClient.java |    2 --
 1 files changed, 0 insertions(+), 2 deletions(-)

diff --git a/src/hdfs/org/apache/hadoop/hdfs/DFSClient.java b/src/hdfs/org/apache/hadoop/hdfs/DFSClient.java
index 903c599..ec60c12 100644
--- a/src/hdfs/org/apache/hadoop/hdfs/DFSClient.java
+++ b/src/hdfs/org/apache/hadoop/hdfs/DFSClient.java
@@ -1604,7 +1604,6 @@ public class DFSClient implements FSConstants, java.io.Closeable {
       // Connect to best DataNode for desired Block, with potential offset
       //
       DatanodeInfo chosenNode = null;
-      failures = 0;
       while (s == null) {
         DNAddrPair retval = chooseDataNode(targetBlock);
         chosenNode = retval.info;
@@ -1805,7 +1804,6 @@ public class DFSClient implements FSConstants, java.io.Closeable {
       Socket dn = null;
       int numAttempts = block.getLocations().length;
       IOException ioe = null;
-      failures = 0;
       
       while (dn == null && numAttempts-- > 0 ) {
         DNAddrPair retval = chooseDataNode(block);
-- 
1.6.0.4

