On 3/15/07, Owen Thomas <[EMAIL PROTECTED]> wrote:
Good day to you all.



If I'm going to use Maven to develop a component that will fit in to a
servicemix-jsr181 container, will I need a web-service archetype of some
description? What archetype do people recommend my using? I would also
like to know why.

If you want to deploy your project to the servicemix-jsr181 component,
you want to use either the servicemix-jsr181-annotated-service-unit
Maven archetype or the servicemix-jsr181-wsdl-first-service-unit Maven
Maven archetype to create the JBI service unit (SU) for your project.
This will create a Maven project skeleton for you. Then you'll need to
wrap the SU in a JBI service assembly (SA) for deployment to
ServiceMix. If you're familiar with J2EE development at all, think of
the SU as being equivalent to a WAR file and the SA as being
equivalent to an EAR file. Below are the steps to doing this:

1) Create your project skeleton using either the
servicemix-jsr181-annotated-service-unit Maven archetype or the
servicemix-jsr181-wsdl-first-service-unit Maven Maven archetype:

mvn archetype:create \
-DarchetypeGroupId=org.apache.servicemix.tooling \
-DarchetypeArtifactId=<insert-archetype-name-here> \
-DarchetypeVersion=3.1-incubating \
-DgroupId=<insert-java-package-name-here> \
-DartifactId=<insert-project-name-here> \
-DremoteRepositories=http://people.apache.org/repo/m2-incubating-repository

2) Fill in the skeleton with your project specific artifacts, i.e.,
populate the src/main/resources/xbean.xml configuration file add Java
classes, add dependencies to the pom.xml, etc.

3) Create a SA using the servicemix-service-assembly Maven archetype
to wrap the SU:

mvn archetype:create \
-DarchetypeGroupId=org.apache.servicemix.tooling \
-DarchetypeArtifactId=servicemix-service-assembly \
-DarchetypeVersion=3.1-incubating \
-DgroupId=<insert-java-package-name-here> \
-DartifactId=<insert-project-name-here> \
-DremoteRepositories=http://people.apache.org/repo/m2-incubating-repository

You'll need to add a dependency in the pom.xml for the SU created in
step number 1 above.

4) In the ServiceMix distribution, copy the
servicemix-jsr181-3.1-incubating-installer.zip and the
servicemix-shared-3.1-incubating-installer.zip to the install
directory

5) Copy the SA created in step number 3 above to the ServiceMix deploy
directory

6) Test your SU, possibly by sending messages to it using SoapUI
(http://soapui.org/)

You should now have your application deployed and ready to test or use.

I hope I didn't leave out anything major. If you have any questions,
please let us know.

Bruce
--
perl -e 'print unpack("u30","D0G)[EMAIL 
PROTECTED]&5R\"F)R=6-E+G-N>61E<D\!G;6%I;\"YC;VT*"
);'

Apache Geronimo - http://geronimo.apache.org/
Apache ActiveMQ - http://activemq.org/
Apache ServiceMix - http://servicemix.org/
Castor - http://castor.org/

Reply via email to