[
https://issues.apache.org/jira/browse/HDFS-6874?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14286613#comment-14286613
]
Charles Lamb commented on HDFS-6874:
------------------------------------
[~lianggz],
Thanks for working on this.
In general the patch looks good. I have a few minor comments.
The patch on the trunk needs to be rebased. I didn't check the branch-2 patch,
so it may need to be rebased too.
In general, lots of lines exceed the 80 char limit.
FSOperations.java
s/private static Map blockLocationsToJSON/private static Map
blockLocationsToJSON/
You may want to add java doc for the @param, and @return of that method.
HttpFSFileSystem.java
getFileBlockLocations should have javadoc for the @return. In this method, the
call to HttpFSUtils.validateResponse should probably be changed to
HttpExceptionUtils.validateResponse().
HttpFSServer.java
s/offset,len/offset, len/
Is it correct that passing a len=0 implies Long.MAX_VALUE?
JsonUtil.java
The javadoc formatting for toBlockLocations is messed up a little.
s/IOException{/IOException {/
WebHdfsFileSystem.java
for isWebHDFSJson, s/json){/json) {/ and s/m!=null/m != null/. Also, the
javadoc needs filling in.
Charles
> Add GET_BLOCK_LOCATIONS operation to HttpFS
> -------------------------------------------
>
> Key: HDFS-6874
> URL: https://issues.apache.org/jira/browse/HDFS-6874
> Project: Hadoop HDFS
> Issue Type: Bug
> Affects Versions: 2.4.1
> Reporter: Gao Zhong Liang
> Assignee: Gao Zhong Liang
> Attachments: HDFS-6874-branch-2.6.0.patch, HDFS-6874.patch
>
>
> GET_BLOCK_LOCATIONS operation is missing in HttpFS, which is already
> supported in WebHDFS. For the request of GETFILEBLOCKLOCATIONS in
> org.apache.hadoop.fs.http.server.HttpFSServer, BAD_REQUEST is returned so far:
> .......
> case GETFILEBLOCKLOCATIONS: {
> response = Response.status(Response.Status.BAD_REQUEST).build();
> break;
> }
> ........
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)