From 4e699f0383590d6c72cb3ee2294da29a4945922f Mon Sep 17 00:00:00 2001 From: huhaiyang Date: Tue, 11 Jul 2023 15:46:06 +0800 Subject: [PATCH] HDFS-17076. Remove the unused method isSlownodeByNameserviceId in DataNode (#5824). Contributed by Haiyang Hu. Signed-off-by: Ayush Saxena --- .../hadoop/hdfs/server/datanode/BlockPoolManager.java | 7 ------- .../org/apache/hadoop/hdfs/server/datanode/DataNode.java | 4 ---- 2 files changed, 11 deletions(-) diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/BlockPoolManager.java b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/BlockPoolManager.java index 073576546c..1611c3c9ce 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/BlockPoolManager.java +++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/BlockPoolManager.java @@ -308,13 +308,6 @@ Map getBpByNameserviceId() { return bpByNameserviceId; } - boolean isSlownodeByNameserviceId(String nsId) { - if (bpByNameserviceId.containsKey(nsId)) { - return bpByNameserviceId.get(nsId).isSlownode(); - } - return false; - } - boolean isSlownodeByBlockPoolId(String bpId) { if (bpByBlockPoolId.containsKey(bpId)) { return bpByBlockPoolId.get(bpId).isSlownode(); diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/DataNode.java b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/DataNode.java index 41088cf59c..2096f18d31 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/DataNode.java +++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/DataNode.java @@ -4240,10 +4240,6 @@ public DataSetLockManager getDataSetLockManager() { return dataSetLockManager; } - boolean isSlownodeByNameserviceId(String nsId) { - return blockPoolManager.isSlownodeByNameserviceId(nsId); - } - boolean isSlownodeByBlockPoolId(String bpId) { return blockPoolManager.isSlownodeByBlockPoolId(bpId); }