[ 
https://issues.apache.org/jira/browse/HDFS-8489?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Zhe Zhang updated HDFS-8489:
----------------------------
    Attachment: HDFS-8489.02.patch

Updating the patch to remove redundant logic between {{BlockInfo}} and 
{{BlockInfoContiguous}}. 

The main difference between {{BlockInfoStriped}} and {{BlockInfoContiguous}} is 
that in {{BIStriped#triplets}}, the first {{dataBlockNum}} slots are ordered 
based on internal block indices. Therefore the first {{dataBlockNum}} slots 
could have null, and we need an indices array to interpret the slots after 
{{dataBlockNum}}. So only {{addStorage}}, {{removeStorage}}, and {{numNodes}} 
should stay abstract in {{BlockInfo}} and be separately implemented.

[~jingzhao] We discussed similar ideas under HDFS-7285 JIRAs. Let me know if 
the above makes sense to you.

> Subclass BlockInfo to represent contiguous blocks
> -------------------------------------------------
>
>                 Key: HDFS-8489
>                 URL: https://issues.apache.org/jira/browse/HDFS-8489
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>          Components: namenode
>    Affects Versions: 2.7.0
>            Reporter: Zhe Zhang
>            Assignee: Zhe Zhang
>         Attachments: HDFS-8489.00.patch, HDFS-8489.01.patch, 
> HDFS-8489.02.patch
>
>
> As second step of the cleanup, we should make {{BlockInfo}} an abstract class 
> and merge the subclass {{BlockInfoContiguous}} from HDFS-7285 into trunk. The 
> patch should clearly separate where to use the abstract class versus the 
> subclass.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to