dev@glassfish.java.net

Re: target as option or operand?

From: Jane Young <jane.young_at_oracle.com>
Date: Sat, 26 Jun 2010 21:44:55 -0700

Bill Shannon wrote:
> Jane Young wrote on 06/25/2010 06:04 PM:
>> Bill Shannon wrote:
>>> Jane Young wrote on 06/25/10 04:28 PM:
>>>>
>>>> In v2, all the list-* commands take target as operand.
>>>
>>> Why don't they use --target, and take a name of the thing they list
>>> as an operand?
>> What do you mean by the name of the things?
>>
>> For example "list-jndi-resources <target>" lists the names of the
>> jndi-resources in the target.
>
> Right, but why isn't it "list-jndi-resources --target <target>
> <jndi-name>"?
> And "list-applications --target <target> <application-name>"?
>
> Ya, I know, you're thinking "why would I need the list command if I
> already
> knew the name of the thing?" Well, it would tell you whether the thing
> existed or not. And if you allowed patterns, it would only list those
> things that matched the pattern. And if there were options like
> --verbose
> it would only list the extra information for the named things.
>
> Think "ls file".

I see your point.

Is it possible to enhance the command to include the name as well?

"list-jndi-resources name_at_target" or "list-jndi-resources target:name"?

AFAIK, target name cannot include characters like "@" or ":".

And add the --verbose option to include extra information like the
attributes in the jndi element?


>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: dev-help_at_glassfish.dev.java.net
>