From 023b941e3b83f32bc785240dbb1bfce11a987941 Mon Sep 17 00:00:00 2001 From: Yiqun Lin Date: Tue, 14 Mar 2017 17:49:48 +0800 Subject: [PATCH] HDFS-11526. Fix confusing block recovery message. Contributed by Yiqun Lin. --- .../hdfs/server/datanode/BlockRecoveryWorker.java | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/BlockRecoveryWorker.java b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/BlockRecoveryWorker.java index d39d0505882..792b6af4ac5 100644 --- a/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/BlockRecoveryWorker.java +++ b/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/BlockRecoveryWorker.java @@ -167,9 +167,8 @@ public class BlockRecoveryWorker { return; } catch (IOException e) { ++errorCount; - InterDatanodeProtocol.LOG.warn( - "Failed to obtain replica info for block (=" + block - + ") from datanode (=" + id + ")", e); + InterDatanodeProtocol.LOG.warn("Failed to recover block (block=" + + block + ", datanode=" + id + ")", e); } } @@ -429,9 +428,8 @@ public class BlockRecoveryWorker { + rBlock.getNewGenerationStamp() + " is aborted.", ripE); return; } catch (IOException e) { - InterDatanodeProtocol.LOG.warn( - "Failed to obtain replica info for block (=" + block - + ") from datanode (=" + id + ")", e); + InterDatanodeProtocol.LOG.warn("Failed to recover block (block=" + + block + ", datanode=" + id + ")", e); } } checkLocations(syncBlocks.size());