hadoop-hdfs-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Walter Su (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HDFS-8702) Erasure coding: update BlockManager.blockHasEnoughRacks(..) logic for striped block
Date Tue, 14 Jul 2015 02:39:05 GMT

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

Walter Su commented on HDFS-8702:

bq. We should continue use the passed-in parameter "expectedStorageNum", and we only need
to make sure its value is derived from BlockManager#getExpectedReplicaNum which correctly
handles striped blocks with different size.

Assume contiguous block:
the pass-in expectedStorageNum only used to test is it need to check enough racks.
if (expectedStorageNum == 1 || (expectedStorageNum > 1
See, expectedStorageNum=3 has no difference with expectedStorageNum=4. The expected number
of rack, which is 2,  has no relationship with the expectedStorageNum.

As for striped block, expectedStorageNum is useless. Because it always bigger than 1.

1. I think we can use getRealDataBlockNum();
2. activeRacks is useless.
3. It would be better to move the comment to the javadoc of the function.
4. line margin is 80 characters.
5. Indent 4 blank character is enough( Since the function name is long)
+                                         Collection<DatanodeDescriptor> corruptNodes)

> Erasure coding: update BlockManager.blockHasEnoughRacks(..) logic for striped block
> -----------------------------------------------------------------------------------
>                 Key: HDFS-8702
>                 URL: https://issues.apache.org/jira/browse/HDFS-8702
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>            Reporter: Walter Su
>            Assignee: Kai Sasaki
>         Attachments: HDFS-8702-HDFS-7285.00.patch, HDFS-8702-HDFS-7285.01.patch, HDFS-8702-HDFS-7285.02.patch
> Currently blockHasEnoughRacks(..) only guarantees 2 racks. Logic needs updated for striped

This message was sent by Atlassian JIRA

View raw message