users@glassfish.java.net

Re: Improving asadmin interactive mode

From: Sreenivas Munnangi <Sreenivas.Munnangi_at_Sun.COM>
Date: Tue, 11 Jul 2006 10:41:04 -0700

Jane,

Thanks for soliciting input towards improving CLI.

I think, usually before the scripts are finalized, the developers would
like to test the individual commands and options. So in this scenario
the interactive mode will be helpful including prompting for required
options. You may have to priorotize the commands based on the resources.

It is a good idea to enable/disable the interactive mode using the
'--interactive' option. This can be session/environment specific rather
than specifying for every command.

Just my thoughts.

- sreeni

Jane Young-Lau wrote On 07/10/06 04:49 PM,:

> Hi All,
>
> I'd like to solicit your opinion on how CLI (asadmin) prompts for options.
>
> Currently, if --interactive is true, asadmin would prompt for the user
> and password. It does not prompt for the required options.
>
> For example, let's take create-jdbc-resource command:
> >asadmin create-jdbc-resource --interactive jdbc_resource
> CLI014 connectionpoolid is a required option.
>
> Though --interactive is true, the command fails since it requires that
> you enter --connectionpoolid option on the command line. If you
> provide the --connectionpoolid option, the command will prompt the
> user for the user and password:
> >asadmin create-jdbc-resource --interactive --connectionpoolid
> testPool jdbc_resource
> Please enter the admin user name>admin
> Please enter the admin password>
> Command create-jdbc-resource executed successfully.
>
> The user and password options are prompted since I have not login'd to
> the domain using "asadmin login" command.
>
> Would you like to see that asadmin commands also prompt for the
> required options as well as the user/password options? Would this be
> a feature well received? Keep in mind that asadmin is mainly use for
> scripting.
>
> I'd like to know the following:
> YES - adding prompting of required options benefits the usability of
> asadmin
> NO - stay status quo. prompting of user/password is good enough
> Other suggestions?
>
> Let me know your opinion.
>
> Thank you,
> Jane
>
>