[
https://issues.apache.org/jira/browse/HADOOP-2861?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12572438#action_12572438
]
Vinod Kumar Vavilapalli commented on HADOOP-2861:
-------------------------------------------------
Proposing some changes to what Hemanth has given, and summarizing.
The final interface could look something like follows:
* hod allocate cluster-dir min-nodes [options]
* hod deallocate cluster-dir [options]
* hod info cluster-dir [options]
* hod list [options]
* hod-script cluster-dir min-nodes script [options]
So the structure is "hod task [arg [arg ..] [option [option ..]]]", very
similar to what Lohit proposed in the beginning.
First, Cluster-dir and min-nodes are now positional arguments as opposed to the
earlier -m and -D, this is done for various reasons
* This model is more intuitive, in the sense that we absolutely don't need
to do things like "-D cluster-dir -m nodes" for parameters that are actually
"required options"
* They are absolutely needed for the respective command to run and thus
cannot be categorized as options in the first place. This is inline with
comparison of positional arguments(that determine what task needs to be
performed) with options(that describe how a task run could be affected)
* Though positional parameters impose order, which might otherwise be
difficult for users to remember, this is still ok here because we have very few
of them.
* and yes this means typing less (doing away with unnecessary -D, -n, -s
etc.)
After a careful examination, all other parameters can be categorized as
options. This might in turn need us to give defaults to some of the parameters
that don't have one currently, and make some related changes too.
Finally, hod-script is separated and is a wrapper of hod commands, as Hemanth
described. See HADOOP-2897. It's interface imitates the syntax of hod allocate
as close as possible, to minimize any possible user confusion otherwise w.r.t
the argument order.
> [HOD] Improve the user interface for the HOD commands
> -----------------------------------------------------
>
> Key: HADOOP-2861
> URL: https://issues.apache.org/jira/browse/HADOOP-2861
> Project: Hadoop Core
> Issue Type: Improvement
> Components: contrib/hod
> Affects Versions: 0.16.0
> Reporter: Hemanth Yamijala
> Fix For: 0.16.1
>
>
> The current command line for HOD is not user-friendly or conventional.
> Following improvements are required:
> - We shouldn't require the quotes around the operation.
> - Can we define a HOD_CLUSTER_DIR environment variable which would be used by
> default ?
> With these two, one can imagine a very simple command line for HOD. Something
> like:
> hod-allocate 3
> hod-deallocate
> hod-allocate 3 ~/hod-clusters/test
> hod-deallocate ~/hod-clusters/test
> This would also be backward compatible for people who're used to the current
> model.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.