[
https://issues.apache.org/jira/browse/SUBMARINE-57?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Szilard Nemeth updated SUBMARINE-57:
------------------------------------
Attachment: SUBMARINE-57.001.patch
> Add more elaborate message if submarine command is not recognized
> -----------------------------------------------------------------
>
> Key: SUBMARINE-57
> URL: https://issues.apache.org/jira/browse/SUBMARINE-57
> Project: Hadoop Submarine
> Issue Type: Improvement
> Reporter: Szilard Nemeth
> Assignee: Adam Antal
> Priority: Major
> Attachments: SUBMARINE-57.001.patch, SUBMARINE-57.001.patch
>
>
> In {{org.apache.hadoop.yarn.submarine.client.cli.Cli#main}}, we have this
> error handling:
> {code:java}
> if (args[0].equals("job")) {
> String subCmd = args[1];
> if (subCmd.equals(CliConstants.RUN)) {
> new RunJobCli(clientContext).run(moduleArgs);
> } else if (subCmd.equals(CliConstants.SHOW)) {
> new ShowJobCli(clientContext).run(moduleArgs);
> } else {
> printHelp();
> throw new IllegalArgumentException("Unknown option for job");
> }
> } else {
> printHelp();
> throw new IllegalArgumentException("Bad parameters <TODO>");
> }
> {code}
> "Bad parameters <TODO>" need to be replaced with someting making more sense.
--
This message was sent by Atlassian JIRA
(v7.6.14#76016)