[
https://issues.apache.org/jira/browse/HDFS-5891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13899531#comment-13899531
]
Jing Zhao commented on HDFS-5891:
---------------------------------
The patch needs some rebase (JspHelper.java misses one imports). Besides,
# looks like we do not need the configuration parameter any more for bestNodes
methods
# We may still want the following check. Although nodes should not be null in
the current code, it may be better to still do this check.
{code}
- if (nodes == null || nodes.length == 0) {
- throw new IOException("No nodes contain this block");
{code}
+1 after addressing the comments.
> webhdfs should not try connecting the DN during redirection
> -----------------------------------------------------------
>
> Key: HDFS-5891
> URL: https://issues.apache.org/jira/browse/HDFS-5891
> Project: Hadoop HDFS
> Issue Type: Bug
> Reporter: Haohui Mai
> Assignee: Haohui Mai
> Attachments: HDFS-5891.000.patch
>
>
> When the webhdfs server in NN serves an {{OPEN}} request, the NN will
> eventually redirect the request to a DN. The current implementation intends
> to choose the active DNs. The code always connects to the DN in a
> deterministic order to see whether it is active during redirection.
> Although it reduces the chance of the client from connecting to a failed DN,
> this is problematic because:
> # It has no guarantees that the client can connect to that DN even if the NN
> can connect to it.
> # It requires an additional network round-trip for every {{OPEN}} /
> {{CREATE}} request.
> This jira proposes that the NN should choose the DN based on the information
> of the data node manager.
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)