From 561b61cfb1bf4f15d991c878ab028b57f3993d11 Mon Sep 17 00:00:00 2001 From: Giovanni Matteo Fumarola Date: Wed, 12 Dec 2018 11:16:16 -0800 Subject: [PATCH] HDFS-14144. TestPred fails in Trunk. Contributed by Ayush Saxena. --- .../src/test/java/org/apache/hadoop/hdfs/TestPread.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestPread.java b/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestPread.java index 0834d30d38..0a64e268b6 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestPread.java +++ b/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/TestPread.java @@ -676,11 +676,10 @@ private void doPreadTestWithChangedLocations(int maxFailures) Path p = new Path("/test"); String data = "testingmissingblock"; DFSTestUtil.writeFile(dfs, p, data); - + DFSTestUtil.waitForReplication(dfs, p, (short) 2, 10000); FSDataInputStream in = dfs.open(p); List blocks = DFSTestUtil.getAllBlocks(in); LocatedBlock lb = blocks.get(0); - DFSTestUtil.waitForReplication(cluster, lb.getBlock(), 1, 2, 0); blocks = DFSTestUtil.getAllBlocks(in); DatanodeInfo[] locations = null; for (LocatedBlock locatedBlock : blocks) {