<?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/xsd/maven-4.0.0.xsd">

  <modelVersion>4.0.0</modelVersion>
  <parent>
        <groupId>org.jbpm</groupId>
        <artifactId>jbpm-human-task</artifactId>
        <version>5.5.0.Final</version>
  </parent>

  <artifactId>jbpm-human-task-war</artifactId>
  <packaging>war</packaging>

  <name>jBPM :: Human Task WAR</name>

  <dependencies>
    <dependency>
      <groupId>org.jbpm</groupId>
      <artifactId>jbpm-human-task-core</artifactId>
      <exclusions>
        <exclusion>
          <groupId>org.apache.cxf</groupId>
          <artifactId>cxf-rt-frontend-jaxws</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.apache.cxf</groupId>
          <artifactId>cxf-rt-transports-http</artifactId>
        </exclusion>
        <exclusion>
          <groupId>wsdl4j</groupId>
          <artifactId>wsdl4j</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.apache.neethi</groupId>
          <artifactId>neethi</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.apache.ws.xmlschema</groupId>
          <artifactId>xmlschema-core</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.jbpm</groupId>
      <artifactId>jbpm-human-task-hornetq</artifactId>
    </dependency>
    <dependency>
      <groupId>org.jbpm</groupId>
      <artifactId>jbpm-human-task-jms</artifactId>
    </dependency>
    <dependency>
      <groupId>org.jbpm</groupId>
      <artifactId>jbpm-human-task-mina</artifactId>
    </dependency>
    <dependency>
      <groupId>javax.servlet</groupId>
      <artifactId>servlet-api</artifactId>
      <version>2.5</version>
      <!-- Any servlet container supports -->
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-log4j12</artifactId>
    </dependency>
    <dependency>
    	<groupId>com.h2database</groupId>
    	<artifactId>h2</artifactId>
    	<version>1.3.164</version>
    	<scope>test</scope>
    </dependency>
    <dependency>
    	<groupId>org.hornetq</groupId>
    	<artifactId>hornetq-core</artifactId>
    </dependency>
    <dependency>
       <groupId>org.jboss.netty</groupId>
       <artifactId>netty</artifactId>
       <scope>runtime</scope>
    </dependency>

    <!-- Test -->
    <dependency>
    	<groupId>org.hibernate</groupId>
    	<artifactId>hibernate-core</artifactId>
      <scope>runtime</scope>
    </dependency>
    <dependency>
    	<groupId>org.hibernate</groupId>
    	<artifactId>hibernate-entitymanager</artifactId>
      <scope>runtime</scope>
    </dependency>
  </dependencies>
  
  <build>
    <pluginManagement>
     <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-war-plugin</artifactId>
            <configuration>
                <archive>
                    <manifestEntries>
                        <Dependencies>org.jboss.netty</Dependencies>
                    </manifestEntries>
                </archive>
               </configuration>
          </plugin>
       </plugins>
    </pluginManagement>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-antrun-plugin</artifactId>
        <version>1.6</version>
        <executions>
          <execution>
            <id>unpack-war</id>
            <phase>package</phase>
            <configuration>
              <target>
                <unzip
                  src="${project.build.directory}/${project.artifactId}-${project.version}.war"
                  dest="${project.build.directory}/upacked-war" />
              </target>
            </configuration>
            <goals>
              <goal>run</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-assembly-plugin</artifactId>
        <executions>
          <execution>
            <id>ee6</id>
            <phase>package</phase>
            <goals>
              <goal>single</goal>
            </goals>
            <configuration>
              <descriptors>
                <descriptor>src/main/assembly/human-task-war-ee6.xml</descriptor>
              </descriptors>
              <archive>
                <manifestEntries>
                  <Dependencies>org.jboss.netty</Dependencies>
                </manifestEntries>
              </archive>
            </configuration>
          </execution>
          <execution>
            <id>as5</id>
            <phase>package</phase>
            <goals>
              <goal>single</goal>
            </goals>
            <configuration>
              <descriptors>
                <descriptor>src/main/assembly/human-task-war-as5.xml</descriptor>
              </descriptors>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
</project>
