hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jl...@apache.org
Subject hadoop git commit: HDFS-11818. TestBlockManager.testSufficientlyReplBlocksUsesNewRack fails intermittently. Contributed by Nathan Roberts
Date Fri, 12 May 2017 22:48:15 GMT
Repository: hadoop
Updated Branches:
  refs/heads/branch-2.8 dfa2657ab -> f42222a75


HDFS-11818. TestBlockManager.testSufficientlyReplBlocksUsesNewRack fails intermittently. Contributed
by Nathan Roberts

(cherry picked from commit aeca471ec13135064f9605174cd6daa120007b18)


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/f42222a7
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/f42222a7
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/f42222a7

Branch: refs/heads/branch-2.8
Commit: f42222a75ba41613644e077cedef453cf07f02cf
Parents: dfa2657
Author: Jason Lowe <jlowe@yahoo-inc.com>
Authored: Fri May 12 17:47:17 2017 -0500
Committer: Jason Lowe <jlowe@yahoo-inc.com>
Committed: Fri May 12 17:48:00 2017 -0500

----------------------------------------------------------------------
 .../hadoop/hdfs/server/blockmanagement/TestBlockManager.java      | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/f42222a7/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/blockmanagement/TestBlockManager.java
----------------------------------------------------------------------
diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/blockmanagement/TestBlockManager.java
b/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/blockmanagement/TestBlockManager.java
index b846658..111bfa8 100644
--- a/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/blockmanagement/TestBlockManager.java
+++ b/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/blockmanagement/TestBlockManager.java
@@ -153,7 +153,6 @@ public class TestBlockManager {
     Mockito.when(haContext.getState()).thenReturn(haState);
     Mockito.when(haState.shouldPopulateReplQueues()).thenReturn(true);
     Mockito.when(fsn.getHAContext()).thenReturn(haContext);
-    bm.setInitializedReplQueues(true);
     CacheManager cm = Mockito.mock(CacheManager.class);
     Mockito.doReturn(cm).when(fsn).getCacheManager();
     GSet<CachedBlock, CachedBlock> cb =
@@ -897,10 +896,12 @@ public class TestBlockManager {
     StorageReceivedDeletedBlocks srdb =
         new StorageReceivedDeletedBlocks(new DatanodeStorage(ds.getStorageID()),
             rdbiList.toArray(new ReceivedDeletedBlockInfo[rdbiList.size()]));
+    bm.setInitializedReplQueues(true);
     bm.processIncrementalBlockReport(node, srdb);
     // Needed replications should still be 0.
     assertEquals("UC block was incorrectly added to needed Replications",
         0, bm.neededReplications.size());
+    bm.setInitializedReplQueues(false);
   }
 
   private BlockInfo addBlockToBM(long blkId) {


---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-commits-help@hadoop.apache.org


Mime
View raw message