[
https://issues.apache.org/jira/browse/HADOOP-1425?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12498751
]
Raghu Angadi commented on HADOOP-1425:
--------------------------------------
bq. How did you create 'conf'?
just like we create conf anywhere, {{new Configuration();}}, for e.g.. ToolBase
does not create conf.
Actual use case in DFSAdmin.java:
{code}
/**
* main() has some simple utility methods.
* @param argv Command line parameters.
* @exception Exception if the filesystem does not exist.
*/
public static void main(String[] argv) throws Exception {
int res = new DFSAdmin().doMain(new Configuration(), argv);
System.exit(res);
}
{code}
Note that ToolBase forces the subclass to call {{doMain()}} and implement
{{run()}}.
> Rework the various programs in 'examples' to extend ToolBase
> -------------------------------------------------------------
>
> Key: HADOOP-1425
> URL: https://issues.apache.org/jira/browse/HADOOP-1425
> Project: Hadoop
> Issue Type: Improvement
> Components: examples
> Reporter: Arun C Murthy
> Assigned To: Enis Soztutar
> Priority: Minor
> Fix For: 0.14.0
>
>
> Ensuring all 'examples' extend ToolBase will make it easy to tweak various
> config params (via -D switches for e.g.) while running the programs...
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.