[ 
https://issues.apache.org/jira/browse/HDFS-517?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12742082#action_12742082
 ] 

Hairong Kuang commented on HDFS-517:
------------------------------------

Major comments:
1. BlocksMap.addINode allows to add only new blocks to the map. It should also 
allow to replace an existing BlockInfo by a new BlockInfo. This is needed for 
converting an UnderConstrution block to be a Complete Block and vice visa.
2. INodeFileUnderConstruction#newBlockInfo should not create 
BlockInfoUnderConstruction all the time because an under construction file may 
also contain complete blocks.
3. BlockInfoUnderConstruction should also keep track of the generation stamp of 
each replica.
4.FsNamesystem#getBlocks should exclude blocks under construction because the 
balancer should not move under construction blocks.


> Introduce BlockInfoUnderConstruction to reflect block replica states while 
> writing.
> -----------------------------------------------------------------------------------
>
>                 Key: HDFS-517
>                 URL: https://issues.apache.org/jira/browse/HDFS-517
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>          Components: name-node
>    Affects Versions: 0.21.0
>            Reporter: Konstantin Shvachko
>            Assignee: Konstantin Shvachko
>             Fix For: Append Branch
>
>         Attachments: Append-UCBlock.patch, Append-UCBlock.patch
>
>
> Currently when a block is created its locations are stored in 
> {{INodeFileUnderConstruction.targets}}, which correspond to the last 
> allocated block. With the new append design we will need to keep track of 
> block replicas for several blocks rather than just the last one.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to