diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/java/org/apache/hadoop/hdfs/protocol/Block.java b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/java/org/apache/hadoop/hdfs/protocol/Block.java index 23bfa95b4f..4128eced0a 100644 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/java/org/apache/hadoop/hdfs/protocol/Block.java +++ b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/java/org/apache/hadoop/hdfs/protocol/Block.java @@ -162,7 +162,9 @@ public void setGenerationStamp(long stamp) { */ public static String toString(final Block b) { StringBuilder sb = new StringBuilder(); - b.appendStringTo(sb); + sb.append(BLOCK_FILE_PREFIX). + append(b.blockId).append("_"). + append(b.generationStamp); return sb.toString(); }