<?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>core</artifactId>
    <version>3.2.3</version>
  </parent>

  <artifactId>servicemix-core</artifactId>
  <packaging>jar</packaging>
  <name>ServiceMix :: Core</name>

  <dependencies>
    <dependency>
      <groupId>org.apache.servicemix</groupId>
      <artifactId>servicemix-jbi</artifactId>
    </dependency>
    <dependency>
      <groupId>org.apache.servicemix</groupId>
      <artifactId>servicemix-services</artifactId>
    </dependency>
    <dependency>
      <groupId>log4j</groupId>
      <artifactId>log4j</artifactId>
      <optional>true</optional>
    </dependency>
    <dependency>
      <groupId>xml-apis</groupId>
      <artifactId>xml-apis</artifactId>
    </dependency>
    <dependency>
      <groupId>org.apache.geronimo.modules</groupId>
      <artifactId>geronimo-connector</artifactId>
      <optional>true</optional>
    </dependency>
    <dependency>
      <groupId>org.apache.geronimo.modules</groupId>
      <artifactId>geronimo-transaction</artifactId>
      <optional>true</optional>
    </dependency>

    <dependency>
      <groupId>org.apache.activemq</groupId>
      <artifactId>activemq-core</artifactId>
    </dependency>
    <dependency>
      <groupId>org.apache.activemq</groupId>
      <artifactId>activemq-ra</artifactId>
      <optional>true</optional>
    </dependency>

    <dependency>
      <groupId>commons-logging</groupId>
      <artifactId>commons-logging</artifactId>
    </dependency>

    <dependency>
      <groupId>org.apache.geronimo.specs</groupId>
      <artifactId>geronimo-jms_1.1_spec</artifactId>
    </dependency>
    <dependency>
      <groupId>org.apache.geronimo.specs</groupId>
      <artifactId>geronimo-jta_1.0.1B_spec</artifactId>
    </dependency>
    <dependency>
      <groupId>org.apache.geronimo.specs</groupId>
      <artifactId>geronimo-j2ee-management_1.0_spec</artifactId>
    </dependency>
    <dependency>
      <groupId>org.apache.geronimo.specs</groupId>
      <artifactId>geronimo-j2ee-jacc_1.0_spec</artifactId>
    </dependency>
    <dependency>
      <groupId>org.apache.geronimo.specs</groupId>
      <artifactId>geronimo-j2ee-connector_1.5_spec</artifactId>
    </dependency>
    <dependency>
      <groupId>org.apache.xbean</groupId>
      <artifactId>xbean-server</artifactId>
    </dependency>
    <dependency>
      <groupId>org.apache.xbean</groupId>
      <artifactId>xbean-spring</artifactId>
    </dependency>

    <dependency>
      <groupId>commons-collections</groupId>
      <artifactId>commons-collections</artifactId>
    </dependency>

    <dependency>
      <groupId>org.springframework</groupId>
      <artifactId>spring-context</artifactId>
      <version>${spring-version}</version>
    </dependency>
    <dependency>
      <groupId>org.springframework</groupId>
      <artifactId>spring-jmx</artifactId>
      <version>${spring-version}</version>
    </dependency>
    <dependency>
      <groupId>org.springframework</groupId>
      <artifactId>spring-dao</artifactId>
      <version>${spring-version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.springframework</groupId>
      <artifactId>spring-remoting</artifactId>
      <version>${spring-version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>mx4j</groupId>
      <artifactId>mx4j</artifactId>
    </dependency>
    <dependency>
      <groupId>mx4j</groupId>
      <artifactId>mx4j-remote</artifactId>
    </dependency>

    <dependency>
      <groupId>org.jencks</groupId>
      <artifactId>jencks</artifactId>
    </dependency>
    <dependency>
      <groupId>org.apache.geronimo.modules</groupId>
      <artifactId>geronimo-connector</artifactId>
    </dependency>
    <dependency>
      <groupId>org.apache.geronimo.modules</groupId>
      <artifactId>geronimo-transaction</artifactId>
    </dependency>
    <dependency>
      <groupId>com.thoughtworks.xstream</groupId>
      <artifactId>xstream</artifactId>
    </dependency>
    <dependency>
      <groupId>wsdl4j</groupId>
      <artifactId>wsdl4j</artifactId>
      <optional>true</optional>
    </dependency>
    <dependency>
      <groupId>org.apache.woden</groupId>
      <artifactId>woden</artifactId>
      <version>${woden-version}</version>
      <optional>true</optional>
    </dependency>
    <dependency>
      <groupId>jaxen</groupId>
      <artifactId>jaxen</artifactId>
    </dependency>
    <dependency>
      <groupId>commons-beanutils</groupId>
      <artifactId>commons-beanutils-core</artifactId>
    </dependency>
    <dependency>
      <groupId>commons-lang</groupId>
      <artifactId>commons-lang</artifactId>
    </dependency>
    <dependency>
      <groupId>xalan</groupId>
      <artifactId>xalan</artifactId>
    </dependency>
    <dependency>
      <groupId>xerces</groupId>
      <artifactId>xercesImpl</artifactId>
    </dependency>
    <dependency>
      <groupId>stax</groupId>
      <artifactId>stax-api</artifactId>
    </dependency>
    <dependency>
      <groupId>org.codehaus.woodstox</groupId>
      <artifactId>wstx-asl</artifactId>
    </dependency>
    <!--  
    <dependency>
      <groupId>stax-utils</groupId>
      <artifactId>stax-utils</artifactId>
    </dependency>
    -->
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
    </dependency>
    <dependency>
      <groupId>xmlbeans</groupId>
      <artifactId>xmlpublic</artifactId>
      <optional>true</optional>
    </dependency>
    <dependency>
      <groupId>xmlbeans</groupId>
      <artifactId>xbean</artifactId>
      <optional>true</optional>
    </dependency>
    <dependency>
      <groupId>org.logicblaze.lingo</groupId>
      <artifactId>lingo</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>hsqldb</groupId>
      <artifactId>hsqldb</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>easymock</groupId>
      <artifactId>easymock</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>commons-lang</groupId>
      <artifactId>commons-lang</artifactId>
    </dependency>
    <dependency>
      <groupId>ant</groupId>
      <artifactId>ant</artifactId>
      <optional>true</optional>
    </dependency>
    <dependency>
      <groupId>commons-io</groupId>
      <artifactId>commons-io</artifactId>
      <optional>true</optional>
    </dependency>
    
    <dependency>
      <groupId>tranql</groupId>
      <artifactId>tranql-connector</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.derby</groupId>
      <artifactId>derby</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.objectweb.howl</groupId>
      <artifactId>howl</artifactId>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>
    <resources>
      <resource>
        <directory>src/main/resources</directory>
        <includes>
          <include>**/*</include>
        </includes>
      </resource>
      <resource>
        <directory>target/generated</directory>
        <includes>
          <include>**/*</include>
        </includes>
      </resource>
    </resources>
    <testResources>
      <testResource>
        <directory>src/test/resources</directory>
        <includes>
          <include>**/*.properties</include>
          <include>**/*.x*</include>
          <include>**/*.wsdl</include>
          <include>**/*.jks</include>
          <include>**/*.zip</include>
          <include>**/*.txt</include>
          <include>**/*.csv</include>
        </includes>
      </testResource>
      <testResource>
        <directory>src/test/components</directory>
        <includes>
          <include>**/*.jar</include>
          <include>**/*.x*</include>
          <include>**/*.zip</include>
        </includes>
      </testResource>
      <testResource>
        <directory>src/test/assemblies</directory>
        <includes>
          <include>**/*.jar</include>
          <include>**/*.zip</include>
        </includes>
      </testResource>
      <testResource>
        <directory>src/test/java</directory>
        <includes>
          <include>**/*.jar</include>
          <include>**/*.zip</include>
        </includes>
      </testResource>
    </testResources>
    <plugins>
      <plugin>
        <groupId>org.apache.servicemix</groupId>
        <artifactId>build</artifactId>
        <executions>
          <execution>
            <goals>
              <goal>spring.schemas</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.xbean</groupId>
        <artifactId>maven-xbean-plugin</artifactId>
        <executions>
          <execution>
            <configuration>
              <namespace>http://servicemix.apache.org/config/1.0</namespace>
              <schema>target/xbean/servicemix.xsd</schema>
            </configuration>
            <goals>
              <goal>mapping</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
        <configuration>
          <forkMode>always</forkMode>
          <workingDirectory>${basedir}</workingDirectory>
          <includes>
            <include>**/*Test.*</include>
          </includes>
          <excludes>
            <!--  exclude abstract tests -->
            <exclude>**/Abstract*.*</exclude>
            <exclude>**/*$*</exclude>

            <exclude>**/SubscriptionTest.*</exclude>
            <exclude>**/MultipleJMSFlowTest.*</exclude>
            <exclude>**/MultipleFlowsTest.*</exclude>
            <exclude>**/RemoteServiceMixClientTest.*</exclude>
            <exclude>**/JCAFlowTest.*</exclude>
            <exclude>**/JMSFlowTest.*</exclude>

            <exclude>**/TransactionsTest.*</exclude>
            <exclude>**/JcaFlowTransactionTest.*</exclude>
            <exclude>**/JcaFlowPersistentTest.*</exclude>
            <exclude>**/StatelessJmsFlowTest.*</exclude>
            <exclude>**/StatelessJcaFlowTest.*</exclude>
            <exclude>**/ClientFactoryTest.*</exclude>

            <exclude>**/JcaFlowWithTxLogTest.*</exclude>

            <!-- fails in linux OS -->
            <exclude>**/ClassLoaderTest.*</exclude>
            <exclude>**/JbiTaskTest.*</exclude>
            <exclude>**/DeploymentMessageTest.*</exclude>
            <exclude>**/AdminServiceTest.*</exclude>

            <exclude>**/ManagementContextTest.*</exclude>
            <exclude>**/ServiceUnitTest.*</exclude>
            
            <exclude>**/SimpleClusterSendSyncTest.*</exclude>
            <exclude>**/InstallComponentTaskTest.*</exclude>
            <exclude>**/DeployAndListServiceAssemblyTasksTest.*</exclude>
            <exclude>**/ManagementAttributesTest.*</exclude>

          </excludes>
        </configuration>
      </plugin>
    </plugins>
  </build>

    <!--
        Checkstyle chokes on files containing non-ascii characters when
        using the ibmjdk, so add a profile here to allow checkstyle to
        skip those two test source files.
    -->
    <profiles>
        <profile>
            <id>ibmjdk</id>
            <activation>
                <property>
                    <name>java.vendor</name>
                    <value>IBM Corporation</value>
                </property>
            </activation>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-checkstyle-plugin</artifactId>
                        <dependencies>
                            <dependency>
                                <groupId>org.apache.servicemix</groupId>
                                <artifactId>build</artifactId>
                                <version>${servicemix-version}</version>
                            </dependency>
                        </dependencies>
                        <!-- Skip StaxSourceTest and SourceTransformerTest -->
                        <configuration>
                            <excludes>**/*Source*Test.java</excludes>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
</project>
