You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by ant elder <an...@gmail.com> on 2009/04/16 09:31:41 UTC

How adding a Maven Tuscany plugin for running contributions?

If anyone is looking for a reasonable simple self contained fun bit of
work to do how about a new maven plugin to run SCA contributions. The
archetypes we have for creating Tuscany webapps have the Jetty plugin
configured so that you can run them by simply doing "mvn jetty:run"
(see http://cwiki.apache.org/confluence/display/TUSCANYWIKI/Tuscany+Maven+Archetypes).
We could have the same type of thing for running SCA JAR and ZIP
contributions with "mvn tuscany:run" (or mvn sca:run?). I'd help get
started if anyone is interested, or look at the Jetty plugin for
ideas: http://svn.codehaus.org/jetty/jetty/trunk/jetty-maven-plugin/.

   ...ant

Re: How adding a Maven Tuscany plugin for running contributions?

Posted by ant elder <an...@gmail.com>.
On Thu, Apr 16, 2009 at 5:00 PM, ant elder <an...@gmail.com> wrote:
> On Thu, Apr 16, 2009 at 4:51 PM, Raymond Feng <en...@gmail.com> wrote:
>>
>> Hi,
>>
>> I'm not sure if there is a big value of doing this if I understand your
proposal correctly.
>>
>> The SCA deployment story is very different from the web application which
is the standard that Jetty supports. Typically, an SCA composite application
may consist of more than one contributions within the SCA domain.
>
> Any dependent contributions could be defined in the plugin config in
> the pom.xml so that should be fine.
>
>>
>> BTW, we already have the launcher, can't we just use that?
>>
>
> The current launchers don't work from the maven command (AFAIK?) and
> thats what i think would make this useful. But yes otherwise the
> launchers are quite similar and that demonstrates there is value in
> running contributions like this doesn't it :)
>
>    ...ant
>

To show what i meant i've committed a strawman plugin for this in r766438
and updated the jar and zip contribution archetypes to support it.

You don't need to install or build anything to try this out, just do:

  mvn archetype:generate -DarchetypeCatalog=http://tuscany.apache.org

choose option 2 for a zip contribution, enter some group and artifactid and
hit enter to take the defaults on the others prompts, then change into the
newly created artifactid directory and do:

  mvn tuscany:run

and you should see "Hello world" output from the contributions eagerinit
method.

Something else that could be interesting would be to add a goal to create a
tuscany runtime so you do "mvn tuscany:create-runtime" and it in the target
folder it outputs all the tuscany jars and folders needed to run, it could
interrogate the contributions to find all the extension required so it only
includes the necessary jars.

  ...ant

Re: How adding a Maven Tuscany plugin for running contributions?

Posted by ant elder <an...@gmail.com>.
On Thu, Apr 16, 2009 at 4:51 PM, Raymond Feng <en...@gmail.com> wrote:
>
> Hi,
>
> I'm not sure if there is a big value of doing this if I understand your proposal correctly.
>
> The SCA deployment story is very different from the web application which is the standard that Jetty supports. Typically, an SCA composite application may consist of more than one contributions within the SCA domain.

Any dependent contributions could be defined in the plugin config in
the pom.xml so that should be fine.

>
> BTW, we already have the launcher, can't we just use that?
>

The current launchers don't work from the maven command (AFAIK?) and
thats what i think would make this useful. But yes otherwise the
launchers are quite similar and that demonstrates there is value in
running contributions like this doesn't it :)

   ...ant

Re: How adding a Maven Tuscany plugin for running contributions?

Posted by Raymond Feng <en...@gmail.com>.
Hi,

I'm not sure if there is a big value of doing this if I understand your 
proposal correctly.

The SCA deployment story is very different from the web application which is 
the standard that Jetty supports. Typically, an SCA composite application 
may consist of more than one contributions within the SCA domain.

BTW, we already have the launcher, can't we just use that?

Thanks,
Raymond
--------------------------------------------------
From: "ant elder" <an...@gmail.com>
Sent: Thursday, April 16, 2009 12:31 AM
To: <de...@tuscany.apache.org>
Subject: How adding a Maven Tuscany plugin for running contributions?

> If anyone is looking for a reasonable simple self contained fun bit of
> work to do how about a new maven plugin to run SCA contributions. The
> archetypes we have for creating Tuscany webapps have the Jetty plugin
> configured so that you can run them by simply doing "mvn jetty:run"
> (see 
> http://cwiki.apache.org/confluence/display/TUSCANYWIKI/Tuscany+Maven+Archetypes).
> We could have the same type of thing for running SCA JAR and ZIP
> contributions with "mvn tuscany:run" (or mvn sca:run?). I'd help get
> started if anyone is interested, or look at the Jetty plugin for
> ideas: http://svn.codehaus.org/jetty/jetty/trunk/jetty-maven-plugin/.
>
>   ...ant