<?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">
<!--

    Licensed to the Apache Software Foundation (ASF) under one or more
    contributor license agreements.  See the NOTICE file distributed with
    this work for additional information regarding copyright ownership.
    The ASF licenses this file to You under the Apache License, Version 2.0
    (the "License"); you may not use this file except in compliance with
    the License.  You may obtain a copy of the License at

       http://www.apache.org/licenses/LICENSE-2.0

    Unless required by applicable law or agreed to in writing, software
    distributed under the License is distributed on an "AS IS" BASIS,
    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    See the License for the specific language governing permissions and
    limitations under the License.
-->
  <modelVersion>4.0.0</modelVersion>

  <parent>
    <groupId>org.apache.servicemix</groupId>
    <artifactId>components-pom</artifactId>
    <version>3</version>
  </parent>
  
  <groupId>org.apache.servicemix</groupId>
  <artifactId>servicemix-cxf-bc</artifactId>
  <version>2009.01</version>
  <packaging>jbi-component</packaging>
  
  <name>ServiceMix :: CXF Binding Component</name>
  <description>A CXF Binding Component</description>

  <prerequisites>
    <maven>2.0.6</maven>
  </prerequisites>
  
  <scm>
    <connection>scm:svn:http://svn.apache.org/repos/asf/servicemix/components/bindings/servicemix-cxf-bc/tags/servicemix-cxf-bc-2009.01</connection>
    <developerConnection>scm:svn:https://svn.apache.org/repos/asf/servicemix/components/bindings/servicemix-cxf-bc/tags/servicemix-cxf-bc-2009.01</developerConnection>
    <url>http://svn.apache.org/viewcvs.cgi/servicemix/components/bindings/servicemix-cxf-bc/tags/servicemix-cxf-bc-2009.01</url>
  </scm>

  <properties>
    <previous.releases>3.1.2,3.2,3.2.1,3.2.2,3.2.3,2008.01</previous.releases>
    <servicemix-version>3.3</servicemix-version>
    <servicemix-shared-version>2009.01</servicemix-shared-version>
    <servicemix-cxf-se-version>2009.01</servicemix-cxf-se-version>
    <cxf-version>2.1.4</cxf-version>
    <jetty-version>6.1.14</jetty-version>
    <spring-version>2.5.6</spring-version>
    <derby-version>10.4.1.3</derby-version>
    <surefire.fork.mode>pertest</surefire.fork.mode>

    <servicemix.osgi.import>
        org.apache.cxf*;version="[2.1.0,3.0.0)",
        org.apache.servicemix.common,
        org.apache.servicemix.common.osgi,
        org.apache.servicemix.executors.impl,
        org.apache.xbean.spring.context.v2,
        org.springframework.beans.factory.xml,
        sun.misc;resolution:=optional,
        *
    </servicemix.osgi.import>
    <servicemix.osgi.export>
        org.apache.servicemix.cxfbc*;version=${project.version},
        META-INF.services.org.apache.xbean.spring.http.servicemix.apache.org.cxfbc
    </servicemix.osgi.export>
    <servicemix.osgi.bundles>
        org.apache.cxf.cxf-bundle,
        org.springframework.core,
        org.springframework.beans,
        org.springframework.context
    </servicemix.osgi.bundles>
  </properties>

  <dependencies>
    <dependency>
      <groupId>org.apache.servicemix.specs</groupId>
      <artifactId>org.apache.servicemix.specs.jbi-api-1.0</artifactId>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.servicemix</groupId>
      <artifactId>servicemix-core</artifactId>
      <version>${servicemix-version}</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
         <groupId>org.apache.servicemix</groupId>
         <artifactId>servicemix-jbi</artifactId>
        </exclusion>
        <exclusion>
         <groupId>org.apache.servicemix</groupId>
         <artifactId>servicemix-services</artifactId>
        </exclusion>
        <exclusion>
         <groupId>org.apache.activemq</groupId>
         <artifactId>activemq-core</artifactId>
        </exclusion>
        <exclusion>
         <groupId>org.apache.activemq</groupId>
         <artifactId>activemq-pool</artifactId>
        </exclusion>
        <exclusion>
         <groupId>org.apache.activemq</groupId>
         <artifactId>activeio-core</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
        <groupId>org.apache.activemq</groupId>
         <artifactId>activemq-core</artifactId>
         <version>5.2.0</version>  
         <scope>test</scope>
    </dependency>
    <dependency>
        <groupId>org.apache.activemq</groupId>
         <artifactId>activemq-pool</artifactId>
         <version>5.2.0</version>
         <scope>test</scope>
    </dependency>
    <dependency>
        <groupId>org.apache.activemq</groupId>
         <artifactId>activeio-core</artifactId>
         <version>3.1.0</version>
         <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.servicemix</groupId>
      <artifactId>servicemix-utils</artifactId>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.servicemix</groupId>
      <artifactId>servicemix-shared</artifactId>
      <version>${servicemix-shared-version}</version>
    </dependency>
    <dependency>
      <groupId>org.apache.cxf</groupId>
      <artifactId>cxf-rt-frontend-jaxws</artifactId>
      <version>${cxf-version}</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.geronimo.specs</groupId>
      <artifactId>geronimo-ws-metadata_2.0_spec</artifactId>
      <version>1.1.2</version>
    </dependency>
    <dependency>
      <groupId>org.apache.cxf</groupId>
      <artifactId>cxf-rt-ws-policy</artifactId>
      <version>${cxf-version}</version>
    </dependency>
    <dependency>
      <groupId>org.apache.cxf</groupId>
      <artifactId>cxf-rt-ws-addr</artifactId>
      <version>${cxf-version}</version>
    </dependency>
    <dependency>
      <groupId>org.apache.cxf</groupId>
      <artifactId>cxf-rt-ws-rm</artifactId>
      <version>${cxf-version}</version>
    </dependency>
    <dependency>
      <groupId>org.apache.cxf</groupId>
      <artifactId>cxf-rt-ws-security</artifactId>
      <version>${cxf-version}</version>
    </dependency>
    <dependency>
      <groupId>org.apache.cxf</groupId>
      <artifactId>cxf-rt-bindings-soap</artifactId>
      <version>${cxf-version}</version>
    </dependency>
    <dependency>
      <groupId>org.apache.cxf</groupId>
      <artifactId>cxf-rt-transports-http-jetty</artifactId>
      <version>${cxf-version}</version>
    </dependency>
    <dependency>
      <groupId>org.apache.cxf</groupId>
      <artifactId>cxf-rt-transports-jms</artifactId>
      <version>${cxf-version}</version>
    </dependency>
    <dependency>
      <groupId>org.apache.cxf</groupId>
      <artifactId>cxf-testutils</artifactId>
      <version>${cxf-version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.mortbay.jetty</groupId>
      <artifactId>jetty</artifactId>
      <version>${jetty-version}</version>
    </dependency>
    <dependency>
      <groupId>org.mortbay.jetty</groupId>
      <artifactId>jetty-sslengine</artifactId>
      <version>${jetty-version}</version>
    </dependency>
    <dependency>
      <groupId>org.mortbay.jetty</groupId>
      <artifactId>jetty-util</artifactId>
      <version>${jetty-version}</version>
    </dependency>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
    </dependency>
    <dependency>
      <groupId>org.apache.servicemix</groupId>
      <artifactId>servicemix-cxf-se</artifactId>
      <version>${servicemix-cxf-se-version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.springframework</groupId>
      <artifactId>spring-context-support</artifactId>
    </dependency>
    <dependency>
      <groupId>org.springframework</groupId>
      <artifactId>spring-aop</artifactId>
    </dependency>
    <dependency>
      <groupId>org.springframework</groupId>
      <artifactId>spring-context</artifactId>
    </dependency>
    <dependency>
      <groupId>org.springframework</groupId>
      <artifactId>spring-beans</artifactId>
    </dependency>
    <dependency>
      <groupId>org.springframework</groupId>
      <artifactId>spring-core</artifactId>
    </dependency>
    <dependency>
      <groupId>org.apache.derby</groupId>
      <artifactId>derby</artifactId>
      <version>${derby-version}</version>
      <scope>provided</scope>
    </dependency>
    
    <dependency>
      <groupId>org.apache.woden</groupId>
      <artifactId>woden</artifactId>
      <version>1.0.0M6</version>
      <scope>provided</scope>
      <exclusions>
        <exclusion>
            <groupId>org.apache.ws.commons.axiom</groupId>
            <artifactId>axiom-impl</artifactId>
        </exclusion>
        <exclusion>
            <groupId>org.apache.ws.commons.axiom</groupId>
            <artifactId>axiom-api</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>commons-logging</groupId>
      <artifactId>commons-logging</artifactId>
    </dependency>
    <dependency>
      <groupId>org.apache.geronimo.specs</groupId>
      <artifactId>geronimo-activation_1.1_spec</artifactId>
      <version>1.0.2</version>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>stax</groupId>
      <artifactId>stax-api</artifactId>
    </dependency>
    <dependency>
      <groupId>org.codehaus.woodstox</groupId>
      <artifactId>wstx-asl</artifactId>
    </dependency>
    <dependency>
      <groupId>wsdl4j</groupId>
      <artifactId>wsdl4j</artifactId>
    </dependency>
    <dependency>
      <groupId>xalan</groupId>
      <artifactId>xalan</artifactId>
    </dependency>
    <dependency>
      <groupId>xerces</groupId>
      <artifactId>xercesImpl</artifactId>
    </dependency>
    <dependency>
      <groupId>xml-apis</groupId>
      <artifactId>xml-apis</artifactId>
    </dependency>
    
    <dependency>
      <groupId>org.apache.ws.commons.neethi</groupId>
      <artifactId>neethi</artifactId>
      <version>2.0</version>
      <exclusions>
        <exclusion>
          <groupId>org.apache.ws.commons.axiom</groupId>
          <artifactId>axiom-api</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.apache.ws.commons.axiom</groupId>
          <artifactId>axiom-impl</artifactId>
        </exclusion>
        <exclusion>
          <groupId>woodstox</groupId>
          <artifactId>wstx-asl</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.apache.ws.commons.schema</groupId>
      <artifactId>XmlSchema</artifactId>
      <version>1.4.2</version>
    </dependency>
    <dependency>
      <groupId>org.apache.geronimo.specs</groupId>
      <artifactId>geronimo-jta_1.1_spec</artifactId>
    </dependency>
    <!-- for unit/integration testing -->
    <dependency>
      <groupId>org.apache.servicemix</groupId>
      <artifactId>servicemix-core</artifactId>
      <version>${servicemix-version}</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <groupId>org.springframework</groupId>
          <artifactId>spring-jmx</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
        <groupId>commons-httpclient</groupId>
        <artifactId>commons-httpclient</artifactId>
        <scope>test</scope>
        <version>3.0</version>
        <exclusions>
            <exclusion>
                <groupId>commons-codec</groupId>
                <artifactId>commons-codec</artifactId>
            </exclusion>
        </exclusions>
    </dependency>
    <dependency>
        <groupId>commons-codec</groupId>
        <artifactId>commons-codec</artifactId>
        <scope>test</scope>
        <exclusions>
            <exclusion>
                <groupId>junit</groupId>
                <artifactId>junit</artifactId>
            </exclusion>
        </exclusions>
        <version>1.3</version>
    </dependency>
  </dependencies>
  
  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.servicemix.tooling</groupId>
        <artifactId>jbi-maven-plugin</artifactId>
        <extensions>true</extensions>
        <configuration>
          <type>binding-component</type>
          <component>org.apache.servicemix.cxfbc.CxfBcComponent</component>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.xbean</groupId>
        <artifactId>maven-xbean-plugin</artifactId>
        <executions>
          <execution>
            <goals>
              <goal>mapping</goal>
            </goals>
            <configuration>
              <namespace>http://servicemix.apache.org/cxfbc/1.0</namespace>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
        <configuration>
          <forkMode>${surefire.fork.mode}</forkMode>
          <excludes>
              <exclude>**/CxfBCMtomJMSFlowTest.java</exclude>
              <exclude>**/CxfBcHttpJmsBridgeMtomTest.java</exclude>
          </excludes>
          <systemProperties>
            <property>
              <name>derby.system.home</name>
              <value>${basedir}/target/derby</value>
            </property>
          </systemProperties>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.cxf</groupId>
        <artifactId>cxf-codegen-plugin</artifactId>
        <version>${cxf-version}</version>
        <executions>
          <execution>
            <id>generate-test-sources</id>
            <phase>generate-test-sources</phase>
            <configuration>
              <testSourceRoot>${basedir}/target/generated/test/java</testSourceRoot>
              <wsdlOptions>
                <wsdlOption>
                  <wsdl>${basedir}/src/test/resources/hello_world.wsdl</wsdl>
                  <extraargs>
                    <extraarg>-verbose</extraarg>
                  </extraargs>
                </wsdlOption>
                <wsdlOption>
                  <wsdl>${basedir}/src/test/resources/HelloWorld-DOC.wsdl</wsdl>
                  <extraargs>
                    <extraarg>-verbose</extraarg>
                  </extraargs>
                </wsdlOption>
                <wsdlOption>
                  <wsdl>${basedir}/src/test/resources/org/apache/servicemix/cxfbc/fault/person.wsdl</wsdl>
                  <extraargs>
                    <extraarg>-verbose</extraarg>
                  </extraargs>
                </wsdlOption>
                <wsdlOption>
                  <wsdl>${basedir}/src/test/resources/org/apache/servicemix/cxfbc/interceptors/quote.wsdl</wsdl>
                  <extraargs>
                    <extraarg>-verbose</extraarg>
                  </extraargs>
                </wsdlOption>
                <wsdlOption>
                  <wsdl>${basedir}/src/test/resources/org/apache/servicemix/cxfbc/ws/security/hello_world.wsdl</wsdl>
                  <extraargs>
                    <extraarg>-verbose</extraarg>
                  </extraargs>
                  <catalog>${basedir}/src/test/resources/META-INF/jax-ws-catalog.xml</catalog>  
                  <extraargs>
                    <extraarg>-sn</extraarg>
                    <extraarg>HelloWorldService</extraarg>
                  </extraargs>
                </wsdlOption>
              </wsdlOptions>
            </configuration>
            <goals>
              <goal>wsdl2java</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
  
  <repositories>
    <repository>
        <!-- Contains: jaxb-impl-2.1.4, FastInfoset-1.2.2, saaj-impl-1.3 -->
        <id>java.net</id>
        <url>http://download.java.net/maven/1</url>
        <layout>legacy</layout>
    </repository>
  </repositories>

  <profiles>
    <profile>
      <id>ibmjdk</id>
      <activation>
        <property>
          <name>java.vendor</name>
          <value>IBM Corporation</value>
        </property>
      </activation>
      <!--
        Add the Sun jaxp-ri as a dependency when using the ibm jdk, so that
        cxf's dependency on the Sun saaj can work with the ibm jdk.
      -->
      <dependencies>
        <dependency>
          <groupId>com.sun.xml.parsers</groupId>
          <artifactId>jaxp-ri</artifactId>
          <version>1.4.2</version>
        </dependency>
      </dependencies>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-surefire-plugin</artifactId>
            <configuration>
              <forkMode>${surefire.fork.mode}</forkMode>
              <systemProperties>
                <property>
                  <name>derby.system.home</name>
                  <value>${basedir}/target/derby</value>
                </property>
                <!--
                  With Maven 2.0.7, it's possible that jaxp-ri will be placed
                  in front of woodstox on the classpath. If this happens, cxf
                  will not use woodstox, causing test failures (e.g.,
                  CxfBcProviderConsumerMtomTest). So, set these properties to
                  ensure woodstox is used.  Maven 2.0.9 doesn't require this
                  work-around since it consistently places jaxp-ri at the end
                  of the dependencies.
                -->
                <property>
                  <name>javax.xml.stream.XMLInputFactory</name>
                  <value>com.ctc.wstx.stax.WstxInputFactory</value>
                </property>
                <property>
                  <name>javax.xml.stream.XMLOutputFactory</name>
                  <value>com.ctc.wstx.stax.WstxOutputFactory</value>
                </property>
                <!--
                  To work around an issue with a couple of the security tests
                  we reorder the preference order of two of the jre's
                  Cryptography Package Providers defined in the master
                  security properties file.
                -->
                <property>
                  <name>java.security.properties</name>
                  <value>${basedir}/target/test-classes/ibm.security</value>
                </property>
                <!--
                  Turn down some of the logging to prevent the tests from
                  running too slowly.
                -->
                <property>
                  <name>log4j.configuration</name>
                  <value>${basedir}/target/test-classes/log4j-tests.properties</value>
                </property>
                <property>
                  <name>java.util.logging.config.file</name>
                  <value>${basedir}/target/test-classes/logging.properties</value>
                </property>
                <property>
                    <name>javax.xml.transform.TransformerFactory</name>
                    <value>org.apache.xalan.xsltc.trax.TransformerFactoryImpl</value>
                </property>
              </systemProperties>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>
</project>
