Selaa lähdekoodia

svn merge -c 1503972 merging to branch-2.1 to fix HDFS-4998

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2.1-beta@1503974 13f79535-47bb-0310-9956-ffa450edef68
Kihwal Lee 12 vuotta sitten
vanhempi
commit
c2a52b0000

+ 14 - 0
hadoop-hdfs-project/hadoop-hdfs/CHANGES.txt

@@ -3051,6 +3051,20 @@ Release 2.0.0-alpha - 05-23-2012
     
     HDFS-3039. Address findbugs and javadoc warnings on branch. (todd via atm)
 
+Release 0.23.10 - UNRELEASED
+
+  INCOMPATIBLE CHANGES
+
+  NEW FEATURES
+
+  IMPROVEMENTS
+
+  OPTIMIZATIONS
+
+  BUG FIXES
+
+    HDFS-4998. TestUnderReplicatedBlocks fails intermittently (kihwal)
+
 Release 0.23.9 - UNRELEASED
 
   INCOMPATIBLE CHANGES

+ 2 - 1
hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/blockmanagement/TestUnderReplicatedBlocks.java

@@ -30,7 +30,7 @@ import org.apache.hadoop.hdfs.protocol.ExtendedBlock;
 import org.junit.Test;
 
 public class TestUnderReplicatedBlocks {
-  @Test(timeout=300000) // 5 min timeout
+  @Test(timeout=60000) // 1 min timeout
   public void testSetrepIncWithUnderReplicatedBlocks() throws Exception {
     Configuration conf = new HdfsConfiguration();
     final short REPLICATION_FACTOR = 2;
@@ -49,6 +49,7 @@ public class TestUnderReplicatedBlocks {
       ExtendedBlock b = DFSTestUtil.getFirstBlock(fs, FILE_PATH);
       DatanodeDescriptor dn = bm.blocksMap.nodeIterator(b.getLocalBlock()).next();
       bm.addToInvalidates(b.getLocalBlock(), dn);
+      Thread.sleep(5000);
       bm.blocksMap.removeNode(b.getLocalBlock(), dn);
       
       // increment this file's replication factor