You are viewing a plain text version of this content. The canonical link for it is here.
Posted to hdfs-issues@hadoop.apache.org by "Mingliang Liu (JIRA)" <ji...@apache.org> on 2015/12/01 00:02:11 UTC

[jira] [Updated] (HDFS-9485) Make BlockManager#removeFromExcessReplicateMap accept BlockInfo instead of Block

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

Mingliang Liu updated HDFS-9485:
--------------------------------
    Status: Patch Available  (was: Open)

> Make BlockManager#removeFromExcessReplicateMap accept BlockInfo instead of Block
> --------------------------------------------------------------------------------
>
>                 Key: HDFS-9485
>                 URL: https://issues.apache.org/jira/browse/HDFS-9485
>             Project: Hadoop HDFS
>          Issue Type: Improvement
>          Components: namenode
>            Reporter: Mingliang Liu
>            Assignee: Mingliang Liu
>            Priority: Minor
>         Attachments: HDFS-9485.000.patch
>
>
> The {{BlockManager#removeFromExcessReplicateMap()}} method accepts a {{Block}} which is to remove from {{excessReplicateMap}}. However the {{excessReplicateMap}} maps a StorageID to the set of {{BlockInfo}} that are "extra" for the DataNode of the StorageID. Deleting a sub-class object from a collection provided a base-class object happens to work here.
> Alternatively, we can make the {{removeFromExcessReplicateMap}} accept a {{BlockInfo}} object. As the current call stack is passing {{BlockInfo}} object mostly, the code change should be safe.



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