[
https://issues.apache.org/jira/browse/HDFS-6934?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14184394#comment-14184394
]
Tsz Wo Nicholas Sze commented on HDFS-6934:
-------------------------------------------
[~cnauroth], thanks for the big help on continuing this work. The new patch
looks great. Some minor comments:
- Actually, storage types are always present. For a new client talking to an
old clusters, the storage types will be filled with default type, i.e. DISK;
see PBHelper.convertStorageTypes(List<StorageTypeProto> storageTypesList, int
expectedSize).
{code}
+ // Storage types are ordered to correspond with nodes, so use the
same
+ // index to get storage type. Storage types might not be present.
For
+ // example, the client might be communicating with a cluster running
a
+ // prior version before implementation of storage types.
+ if (storageTypes != null && i < storageTypes.length) {
+ storageType = storageTypes[i];
+ }
{code}
- I suggest to add the information of block, nodes and ignoredNodes to the
exception.
{code}
+ if (chosenNode == null) {
+ throw new IOException("No live nodes contain current block");
+ }
{code}
- DFSOutputStream.initLazyPersist(..) is not removed in the new patch. Also,
the hard coded string "LAZY_PERSIST" in isLazyPersist(..) should be replaced by
HdfsConstants.MEMORY_STORAGE_POLICY_NAME, which was introduced recently.
> Move checksum computation off the hot path when writing to RAM disk
> -------------------------------------------------------------------
>
> Key: HDFS-6934
> URL: https://issues.apache.org/jira/browse/HDFS-6934
> Project: Hadoop HDFS
> Issue Type: Sub-task
> Components: datanode
> Reporter: Arpit Agarwal
> Assignee: Chris Nauroth
> Attachments: HDFS-6934.3.patch, HDFS-6934.4.patch,
> h6934_20141003b.patch, h6934_20141005.patch
>
>
> Since local RAM is considered reliable we can avoid writing checksums on the
> hot path when replicas are being written to a local RAM disk.
> The checksum can be computed by the lazy writer when moving replicas to disk.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)