From 0db04fab20990a28f98deb8cd539119995c89c2c Mon Sep 17 00:00:00 2001 From: litao Date: Wed, 10 Nov 2021 18:16:45 +0800 Subject: [PATCH] HDFS-16298. Improve error msg for BlockMissingException (#3615) Reviewed-by: Hui Fei (cherry picked from commit ea65fc26d80db478f7e49749065c69da7e241bf0) --- .../src/main/java/org/apache/hadoop/hdfs/DFSInputStream.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/java/org/apache/hadoop/hdfs/DFSInputStream.java b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/java/org/apache/hadoop/hdfs/DFSInputStream.java index 4e21133d7e..297bbfa0bc 100644 --- a/hadoop-hdfs-project/hadoop-hdfs-client/src/main/java/org/apache/hadoop/hdfs/DFSInputStream.java +++ b/hadoop-hdfs-project/hadoop-hdfs-client/src/main/java/org/apache/hadoop/hdfs/DFSInputStream.java @@ -1003,7 +1003,7 @@ public class DFSInputStream extends FSInputStream String description = "Could not obtain block: " + blockInfo; DFSClient.LOG.warn(description + errMsg + ". Throwing a BlockMissingException"); - throw new BlockMissingException(src, description, + throw new BlockMissingException(src, description + errMsg, block.getStartOffset()); }