[ 
https://issues.apache.org/jira/browse/HADOOP-7233?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13022848#comment-13022848
 ] 

Aaron T. Myers commented on HADOOP-7233:
----------------------------------------

This was the specific code which led me to suggest that this could be better 
done in a branch:

{code}
/**
*  TODO: A crutch until the text is standardized across commands...
*  Eventually an exception that takes the path as an argument will
*  replace custom text
*  @param path the thing that doesn't exist
*  @returns String in printf format
*/
protected String getFnfText(Path path) {
  throw new RuntimeException(path + ": No such file or directory");
}
{code}

Which obviously should be changed sooner rather than later, and arguably should 
never be in trunk. If the intention is that this will never actually return a 
String, but rather always throw an exception, then you should change the return 
type to be {{vode}}, and the name of the method to "{{throwFnfError}}". It 
should probably also throw an IOException, as we do elsewhere in the code.

Note that, in the Hadoop projects, if you do work on a branch it's OK to do 
"commit-then-review" of the individual issues to speed up the development time. 
You'd then need to get a full review/+1 at branch merge time. I don't feel 
strongly about moving this work to a branch, but others might. Just a 
suggestion.

> Refactor FsShell's ls
> ---------------------
>
>                 Key: HADOOP-7233
>                 URL: https://issues.apache.org/jira/browse/HADOOP-7233
>             Project: Hadoop Common
>          Issue Type: Improvement
>          Components: fs
>    Affects Versions: 0.23.0
>            Reporter: Daryn Sharp
>            Assignee: Daryn Sharp
>             Fix For: 0.23.0
>
>         Attachments: HADOOP-7233.patch
>
>
> Need to refactor ls to conform to new FsCommand class.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to