On this page, we are going to create a Maven project which will contain our SU and SA projects .
Creating the Maven project
We start by creating an empty directory to hold the project. Next, create a pom.xml file in it that contains the common definitions for the entire project. For now, just create a pom.xml that looks like this.
<?xml version="1.0" encoding="UTF-8"?> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>org.apache.servicemix.tutorial</groupId> <artifactId>parent</artifactId> <version>1.0-SNAPSHOT</version> <packaging>pom</packaging> <name>ServiceMix :: CXF WSDL Tutorial</name> <url>http://servicemix.org</url> </project>
Checking the pom.xml
The easiest way to check the pom.xml, is by running Maven from the project directory:
mvn install
If the pom.xml is valid, Maven will copy it to your local repository and report a succesfull build.
[INFO] Scanning for projects... [INFO] ------------------------------------------------------------------------ [INFO] Building ServiceMix :: CXF WSDL Tutorial [INFO] task-segment: [install] [INFO] ------------------------------------------------------------------------ [INFO] [site:attach-descriptor] [INFO] [install:install] [INFO] Installing c:\home\Diplomka\_mySA\tutorial-wsdl-cxf-service\pom.xml to C: \Documents and Settings\vkrejcirik\.m2\repository\org\apache\servicemix\tutorial \parent\1.0-SNAPSHOT\parent-1.0-SNAPSHOT.pom [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESSFUL [INFO] ------------------------------------------------------------------------ [INFO] Total time: 3 seconds [INFO] Finished at: Tue Jul 29 07:53:33 CEST 2008 [INFO] Final Memory: 6M/12M [INFO] ------------------------------------------------------------------------
Next, we are going to create cxf-bc service unit.