From 6a1d7d9ed255f43983667166793e4db16a513881 Mon Sep 17 00:00:00 2001 From: Masatake Iwasaki Date: Tue, 1 Dec 2020 08:06:52 +0900 Subject: [PATCH] HDFS-15677. TestRouterRpcMultiDestination#testGetCachedDatanodeReport fails on trunk. (#2503) --- .../hdfs/server/federation/router/TestRouterRpc.java | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/hadoop-hdfs-project/hadoop-hdfs-rbf/src/test/java/org/apache/hadoop/hdfs/server/federation/router/TestRouterRpc.java b/hadoop-hdfs-project/hadoop-hdfs-rbf/src/test/java/org/apache/hadoop/hdfs/server/federation/router/TestRouterRpc.java index faa3111ea7..09ca0d4582 100644 --- a/hadoop-hdfs-project/hadoop-hdfs-rbf/src/test/java/org/apache/hadoop/hdfs/server/federation/router/TestRouterRpc.java +++ b/hadoop-hdfs-project/hadoop-hdfs-rbf/src/test/java/org/apache/hadoop/hdfs/server/federation/router/TestRouterRpc.java @@ -233,9 +233,13 @@ public class TestRouterRpc { // We decrease the DN heartbeat expire interval to make them dead faster cluster.getCluster().getNamesystem(0).getBlockManager() - .getDatanodeManager().setHeartbeatExpireInterval(5000); + .getDatanodeManager().setHeartbeatInterval(1); cluster.getCluster().getNamesystem(1).getBlockManager() - .getDatanodeManager().setHeartbeatExpireInterval(5000); + .getDatanodeManager().setHeartbeatInterval(1); + cluster.getCluster().getNamesystem(0).getBlockManager() + .getDatanodeManager().setHeartbeatExpireInterval(3000); + cluster.getCluster().getNamesystem(1).getBlockManager() + .getDatanodeManager().setHeartbeatExpireInterval(3000); } @AfterClass @@ -1859,7 +1863,7 @@ public class TestRouterRpc { } return datanodeReport.length == dn.length; } - }, 500, 5 * 1000); + }, 100, 10 * 1000); // The cache should be updated now final DatanodeInfo[] datanodeReport3 =