[ https://issues.apache.org/jira/browse/HDFS-4885?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13799358#comment-13799358 ]
Junping Du commented on HDFS-4885: ---------------------------------- Thanks Luke and Nicholas for comments! bq. More details: BlockPlacementPolicy.verifyBlockPlacement(..) should not refer to HdfsFileStatus as the entire block management layer should not refer to namenode specific implementation so that the block management could possibly support other namespace implementations. +1. It is good to decouple namespace and block management. bq. For RAID, the facebook implementation use srcPath to determine block placement. So the current API may be good enough. so, we only need to change API very slightly (only javadoc and name) that from {code} public int verifyBlockPlacement(String srcPath, LocatedBlock lBlk, int minRacks) {code} To: {code} public int verifyBlockPlacement(String srcPath, LocatedBlock lBlk, int repNumber) {code} Isn't it? > Update verifyBlockPlacement() API in BlockPlacementPolicy > --------------------------------------------------------- > > Key: HDFS-4885 > URL: https://issues.apache.org/jira/browse/HDFS-4885 > Project: Hadoop HDFS > Issue Type: Sub-task > Reporter: Junping Du > Assignee: Junping Du > Labels: BlockPlacementPolicy > Attachments: HDFS-4885.patch, HDFS-4885-v2.patch, HDFS-4885-v3.patch > > > verifyBlockPlacement() has unused parameter -srcPath as its responsibility > just verify single block rather than files under a specific path. Also the > return value (int) does not make sense as the violation of block placement > has other case than number of racks, so boolean value should be better. -- This message was sent by Atlassian JIRA (v6.1#6144)