karaf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Guillaume Nodet <gno...@gmail.com>
Subject Re: Simpler karaf shell command/action definition
Date Wed, 09 May 2012 16:46:09 GMT
Parent templates aren't supported in blueprint so we can't inject into
multiple actions at the same time.

I agree we could simplify the way you describe to have something like, but
the handler would have to support the old and the new namespace I think:

        <shell:action
class="org.apache.karaf.admin.command.ChangeRmiServerPortCommand">
            <property name="adminService" ref="adminService" />
            <shell:completer ref="instanceCompleter" />
        </shell:action>



On Wed, May 9, 2012 at 6:16 PM, Christian Schneider <chris@die-schneider.net
> wrote:

> I think the namespace could be made a bit simpler by only using:
>
> <shell:action class="..">
> <completer ref=""/>
> </shell:action>
>
> So we could skip the command-bundle and we could skip the command.
>
> Additionally it would be great to be able to inject the same dependencies
> into more than one action. Like the parent attribute in spring beans.
>
> Currently for example if we have a service that all commands of a type use
> we have to inject it into each.
>
>
> Christian
>
> Am 09.05.2012 18:05, schrieb Guillaume Nodet:
>
>> That's what we the namespace handler does.  The<action/>  are actually
>>
>> templates.
>> The service publishing is needed at some point so that the shell knows
>> about the commands.
>>
>> I don't really understand how you can really simply the minimum definition
>> we have now:
>>     <command-bundle xmlns="http://karaf.apache.**org/xmlns/shell/v1.0.0<http://karaf.apache.org/xmlns/shell/v1.0.0>
>> ">
>>         <command>
>>             <action class="..."/>
>>         </command>
>>     </command-bundle>
>>
>>
>>
> --
>
> Christian Schneider
> http://www.liquid-reality.de
>
> Open Source Architect
> Talend Application Integration Division http://www.talend.com
>
>


-- 
------------------------
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/
------------------------
FuseSource, Integration everywhere
http://fusesource.com

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message