<?xml version="1.0" encoding="UTF-8"?>
<!--

     Copyright 2005-2015 Red Hat, Inc.

     Red Hat 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.

-->
<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/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion>
  <parent>
    <groupId>io.fabric8.forge</groupId>
    <artifactId>forge-addons</artifactId>
    <version>2.2.129</version>
  </parent>
  <artifactId>camel</artifactId>
  <name>Fabric8 :: Forge Addons :: Camel</name>

  <properties>
    <maven.compiler.source>1.8</maven.compiler.source>
    <maven.compiler.target>1.8</maven.compiler.target>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <!-- to include hawtio version in pom.xml which is needed by camel setup command -->
    <hawtio.version>1.4.60</hawtio.version>
    <!-- docker maven plugin -->
    <docker.version>0.14.1</docker.version>
  </properties>

  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>io.fabric8</groupId>
        <artifactId>fabric8-project</artifactId>
        <version>${fabric8.version}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.forge</groupId>
        <artifactId>forge-bom</artifactId>
        <version>${jboss.forge.version}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.spec</groupId>
        <artifactId>jboss-javaee-6.0</artifactId>
        <version>3.0.2.Final</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
    </dependencies>
  </dependencyManagement>

  <dependencies>
    <dependency>
      <groupId>io.fabric8.forge</groupId>
      <artifactId>utils</artifactId>
      <version>${project.version}</version>
    </dependency>
    <dependency>
      <groupId>io.fabric8.forge</groupId>
      <artifactId>camel-tooling-util</artifactId>
      <version>${project.version}</version>
    </dependency>

    <!-- we use dtos with jackson annotations -->
    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-core</artifactId>
    </dependency>
    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-annotations</artifactId>
    </dependency>
    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-databind</artifactId>
    </dependency>

    <!-- forge provided -->
    <dependency>
      <groupId>org.jboss.forge.addon</groupId>
      <artifactId>maven-api</artifactId>
      <scope>provided</scope>
    </dependency>

    <!--forge addons -->
    <dependency>
      <groupId>org.jboss.forge.addon</groupId>
      <artifactId>maven</artifactId>
      <classifier>forge-addon</classifier>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.jboss.forge.addon</groupId>
      <artifactId>maven-impl-projects</artifactId>
      <version>${jboss.forge.version}</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.jboss.forge.furnace.container</groupId>
      <artifactId>cdi</artifactId>
      <classifier>forge-addon</classifier>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.jboss.forge.addon</groupId>
      <artifactId>ui</artifactId>
      <classifier>forge-addon</classifier>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.jboss.forge.addon</groupId>
      <artifactId>shell</artifactId>
      <classifier>forge-addon</classifier>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.jboss.forge.addon</groupId>
      <artifactId>projects</artifactId>
      <classifier>forge-addon</classifier>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.jboss.forge.addon</groupId>
      <artifactId>parser-java</artifactId>
      <classifier>forge-addon</classifier>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.jboss.forge.addon</groupId>
      <artifactId>parser-xml</artifactId>
      <classifier>forge-addon</classifier>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.jboss.forge.addon</groupId>
      <artifactId>rest-client</artifactId>
      <classifier>forge-addon</classifier>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.jboss.forge.addon</groupId>
      <artifactId>templates</artifactId>
      <classifier>forge-addon</classifier>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.jboss.forge.roaster</groupId>
      <artifactId>roaster-jdt</artifactId>
      <version>${jboss.roaster.version}</version>
      <scope>provided</scope>
    </dependency>

    <!-- camel core and catalog -->
    <dependency>
      <groupId>org.apache.camel</groupId>
      <artifactId>camel-core</artifactId>
      <version>${camel.version}</version>
      <exclusions>
        <exclusion>
          <groupId>org.slf4j</groupId>
          <artifactId>slf4j-api</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.apache.camel</groupId>
      <artifactId>camel-catalog</artifactId>
      <version>${camel.version}</version>
      <exclusions>
        <exclusion>
          <groupId>org.slf4j</groupId>
          <artifactId>slf4j-api</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.apache.camel</groupId>
      <artifactId>camel-catalog-lucene</artifactId>
      <version>${camel.version}</version>
    </dependency>

    <!-- special for adding activemq-camel to the catalog -->
    <!-- we just need the single JAR and not dependencies -->
    <dependency>
      <groupId>org.apache.activemq</groupId>
      <artifactId>activemq-camel</artifactId>
<!--
      <version>${activemq.version}</version>
-->
      <exclusions>
        <exclusion>
          <groupId>org.apache.camel</groupId>
          <artifactId>camel-jms</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.apache.activemq</groupId>
          <artifactId>activemq-spring</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.apache.activemq</groupId>
          <artifactId>activemq-pool</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.slf4j</groupId>
          <artifactId>slf4j-api</artifactId>
        </exclusion>
      </exclusions>
    </dependency>

    <!-- testing -->
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.apache.camel</groupId>
      <artifactId>camel-test</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.camel</groupId>
      <artifactId>camel-cdi</artifactId>
      <scope>test</scope>
    </dependency>

  </dependencies>

  <build>
    <finalName>camel</finalName>
    <plugins>
      <plugin>
        <artifactId>maven-jar-plugin</artifactId>
        <executions>
          <execution>
            <id>create-forge-addon</id>
            <phase>package</phase>
            <goals>
              <goal>jar</goal>
            </goals>
            <configuration>
              <classifier>forge-addon</classifier>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>

  <profiles>
    <profile>
      <id>release</id>
      <activation />
      <build>
        <plugins>
          <plugin>
            <groupId>org.jboss.forge.furnace</groupId>
            <artifactId>furnace-maven-plugin</artifactId>
            <version>${furnace.version}</version>
            <executions>
              <execution>
                <id>generate-dot</id>
                <phase>prepare-package</phase>
                <goals>
                  <goal>generate-dot</goal>
                </goals>
                <configuration>
                  <attach>true</attach>
                </configuration>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>


</project>
