[
https://issues.apache.org/jira/browse/HDFS-14795?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16925927#comment-16925927
]
Íñigo Goiri commented on HDFS-14795:
------------------------------------
Thanks [~leosun08], I think this is more readable now.
For "isWrite()" I would use ifs instead of switch:
{code}
if (stage == PIPELINE_SETUP_STREAMING_RECOVERY) {
return true;
} else if (stage = =PIPELINE_SETUP_APPEND_RECOVERY) {
return true;
} else {
return false;
}
{code}
A minor neat, the indentation DFSConfigKeys#123 doesn't seem consistent.
> Add Throttler for writing block
> -------------------------------
>
> Key: HDFS-14795
> URL: https://issues.apache.org/jira/browse/HDFS-14795
> Project: Hadoop HDFS
> Issue Type: Improvement
> Reporter: Lisheng Sun
> Assignee: Lisheng Sun
> Priority: Minor
> Attachments: HDFS-14795.001.patch, HDFS-14795.002.patch,
> HDFS-14795.003.patch, HDFS-14795.004.patch
>
>
> DataXceiver#writeBlock
> {code:java}
> blockReceiver.receiveBlock(mirrorOut, mirrorIn, replyOut,
> mirrorAddr, null, targets, false);
> {code}
> As above code, DataXceiver#writeBlock doesn't throttler.
> I think it is necessary to throttle for writing block, while add throttler
> in stage of PIPELINE_SETUP_APPEND_RECOVERY or
> PIPELINE_SETUP_STREAMING_RECOVERY.
> Default throttler value is still null.
--
This message was sent by Atlassian Jira
(v8.3.2#803003)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]