Review Board 1.7.22


DFSClient.getBlockLocations returns BlockLocations with no indication that the corresponding blocks are corrupt

Review Request #27 - Created Nov. 2, 2010 and submitted

Patrick Kling
HDFS-1483
Reviewers
hadoop-hdfs
hadoop-hdfs
DFSClient.getBlockLocations returns BlockLocations with no indication that the corresponding blocks are corrupt

When there are no uncorrupted replicas of a block, FSNamesystem.getBlockLocations returns LocatedBlocks corresponding to corrupt blocks. When DFSClient converts these to BlockLocations, the information that the corresponding block is corrupt is lost. We should add a field to BlockLocation to indicate whether the corresponding block is corrupt in order to warn the client that reading this block will fail. This would be especially useful for tools such as RAID FSCK, which could then easily inspect whether data or parity blocks are corrupted without having to make direct RPC calls
TestDFSUtil
Review request changed
Updated (Nov. 3, 2010, 11:33 a.m.)
Incorporated Ram's feedback. Thank you!
Posted (Nov. 3, 2010, 11:41 a.m.)
Looks good to me, but this diff depends on a hadoop-common change, right?
  1. It depends on HADOOP-7013, which can be found here: https://reviews.apache.org/r/26/