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

Vinayakumar B commented on HDFS-8684:
-------------------------------------

{{if (nonExcess.size() <= sblk.getRealTotalBlockNum()) {}}
This seems reasonable,. In fact, before coming to this line of code, this check 
is already done. And this whole check itself can be removed.
Before calling /{{processOverReplicatedBlock}} itself live vs expected replicas 
count check is done. Expected is checked against actual number of blocks itself.

{{size = getPreferredBlockSize() * blockInfoStripedUC.getDataBlockNum();}}
As mentioned already in the comment there, this part is used to update the 
quota. In that case  need to consider parity blocks too. Infact, this part of 
the code is not reachable. If we check the call heirarchy, its only called from 
a snapshot method and only if replication changed, but for striped block this 
is not possible.

> Erasure Coding: fix some block number calculation for striped block
> -------------------------------------------------------------------
>
>                 Key: HDFS-8684
>                 URL: https://issues.apache.org/jira/browse/HDFS-8684
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>            Reporter: Yi Liu
>            Assignee: Yi Liu
>         Attachments: HDFS-8684-HDFS-7285.001.patch
>
>
> in INodeFile#computeFileSize, the file size calucation for underconstruction 
> striped block is incorrect.
> in BlockManager#chooseExcessReplicasStriped, the {{if (nonExcess.size() <= 
> groupSize) {}} is incorrect.



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

Reply via email to