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

Zhe Zhang commented on HDFS-8543:
---------------------------------

Thanks Walter for the update. No worries :) The patch LGTM after addressing the 
following issues:

# Move {{=}} to previous line
{code}
+    final DatanodeStorageInfo delStorageHint
+        = DatanodeStorageInfo.getDatanodeStorageInfo(nonExcess, delNodeHint);
{code}
# We can probably use something like the below to simplify the {{while 
(!duplicated.isEmpty())}} loop (from a quick check of the documentation of 
{{BitSet}}):
{code}
 for (int i = bs.nextSetBit(0); i >= 0; i = bs.nextSetBit(i+1)) {
     // operate on index i here
 }
 {code}
 # What if {{delHint}} points to an internal block with many excess replicas? 
Should we check before clearing it from {{duplicated}}?
 {code}
 +      if (duplicated.get(index)) {
 +        processChosenExcessReplica(nonExcess, delStorageHint, storedBlock);
 +        duplicated.clear(index);
 +      }
 {code}
 # Nit in the test: let's assign a type for the {{HashSet}}
 {code}
     HashSet<Integer> indices = new HashSet();
{code}
# Not necessarily in this JIRA, but we can test different excess patterns, at 
least we should cover the case where an internal block has 3 copies.
 # Looks like the changes in {{CHANGES-HDFS-EC-7285.txt}} and the xml file is 
unrelated.

> Erasure Coding: processOverReplicatedBlock() handles striped block
> ------------------------------------------------------------------
>
>                 Key: HDFS-8543
>                 URL: https://issues.apache.org/jira/browse/HDFS-8543
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>            Reporter: Walter Su
>            Assignee: Walter Su
>         Attachments: HDFS-8543-HDFS-7285.01.patch, 
> HDFS-8543-HDFS-7285.02.patch, HDFS-8543-HDFS-7285.03.patch, 
> HDFS-8543-HDFS-7285.04.patch
>
>
> striped block group could be over replicated when: 1.dead DN comes back. 2. 
> Balancer/Mover copies block before deletes it.
> This jira add logic for processOverReplicatedBlock() handling striped block



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

Reply via email to