diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/datanode/TestBlockRecovery2.java b/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/datanode/TestBlockRecovery2.java index 03d5851f23..8d2df18711 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/datanode/TestBlockRecovery2.java +++ b/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/datanode/TestBlockRecovery2.java @@ -229,8 +229,8 @@ public void testRaceBetweenReplicaRecoveryAndFinalizeBlock() tearDown(); Configuration configuration = new HdfsConfiguration(); - configuration.set( - DFSConfigKeys.DFS_DATANODE_XCEIVER_STOP_TIMEOUT_MILLIS_KEY, "1000"); + configuration.setLong( + DFSConfigKeys.DFS_DATANODE_XCEIVER_STOP_TIMEOUT_MILLIS_KEY, 5000L); MiniDFSCluster cluster = new MiniDFSCluster.Builder(configuration) .numDataNodes(1).build(); try { @@ -257,6 +257,7 @@ public void testRaceBetweenReplicaRecoveryAndFinalizeBlock() dataNode.initReplicaRecovery(recoveringBlock); } } catch (Exception e) { + LOG.error("Something went wrong.", e); recoveryInitResult.set(false); } });