<?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>
  <parent>
    <groupId>org.dashbuilder</groupId>
    <artifactId>dashbuilder-parent</artifactId>
    <version>2.6.0.Final</version>
    <relativePath>../pom.xml</relativePath>
  </parent>

  <artifactId>dashbuilder-webapp</artifactId>
  <packaging>war</packaging>

  <name>Dashbuilder WebApp</name>
  <description>Dashbuilder WebApp</description>

  <properties>
    <!-- Add the absolute path for $JBOSS_HOME below to manage another instance -->
    <errai.jboss.home>${project.build.directory}/wildfly-${version.org.jboss.errai.wildfly.sdm}</errai.jboss.home>
    <gwt.compiler.skip>false</gwt.compiler.skip>
    <gwt.compiler.localWorkers>4</gwt.compiler.localWorkers>
  </properties>

  <dependencyManagement>
    <dependencies>
      <!-- Demo does not compile without older lienzo-core -->
      <dependency>
        <groupId>com.ahome-it</groupId>
        <artifactId>lienzo-core</artifactId>
        <version>${version.com.ahome-it.lienzo-core.charts}</version>
      </dependency>
    </dependencies>
  </dependencyManagement>

  <!-- NOTE: GWT client deps are needed for GWT compilation purposes (scope=provided) -->
  <dependencies>

    <dependency>
      <groupId>org.jboss.xnio</groupId>
      <artifactId>xnio-api</artifactId>
    </dependency>

    <dependency>
      <groupId>org.jboss.spec.javax.annotation</groupId>
      <artifactId>jboss-annotations-api_1.2_spec</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.jboss.spec.javax.servlet</groupId>
      <artifactId>jboss-servlet-api_3.1_spec</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.jboss.spec.javax.servlet.jsp</groupId>
      <artifactId>jboss-jsp-api_2.3_spec</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.jboss.spec.javax.xml.bind</groupId>
      <artifactId>jboss-jaxb-api_2.2_spec</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.jboss.spec.javax.security.jacc</groupId>
      <artifactId>jboss-jacc-api_1.5_spec</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.apache.commons</groupId>
      <artifactId>commons-lang3</artifactId>
    </dependency>

    <!-- Dashbuilder -->

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-server-all</artifactId>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-dataset-cdi</artifactId>
    </dependency>

    <dependency>
      <groupId>org.kie.soup</groupId>
      <artifactId>kie-soup-dataset-api</artifactId>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-client-all</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-common-client</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-dataset-client</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-displayer-api</artifactId>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-displayer-client</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-displayer-screen</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-dataset-editor</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-displayer-editor</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-renderer-default</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-renderer-google</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-renderer-lienzo</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-renderer-chartjs</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-navigation-api</artifactId>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-services-api</artifactId>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-navigation-client</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.dashbuilder</groupId>
      <artifactId>dashbuilder-cms-client</artifactId>
      <scope>provided</scope>
    </dependency>

    <!-- UberFire -->

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-server-all</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-commons</artifactId>
    </dependency>

    <dependency>
      <groupId>org.kie.soup</groupId>
      <artifactId>kie-soup-commons</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-commons-editor-api</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-commons-editor-client</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-api</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-js</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-client-api</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-io</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-backend-api</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-backend-server</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-nio2-api</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-nio2-model</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-workbench-client</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-workbench-processors</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-runtime-plugins-api</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-runtime-plugins-client</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-runtime-plugins-backend</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-layout-editor-client</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-layout-editor-api</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-layout-editor-backend</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-widgets-service-api</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-widgets-properties-editor-api</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-widgets-properties-editor-client</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-widgets-properties-editor-backend</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-workbench-client-views-patternfly</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-widgets-commons</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-widgets-table</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-simple-docks-client</artifactId>
      <scope>provided</scope>
    </dependency>

    <!-- UberFire Preferences. -->
    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-preferences-api</artifactId>
    </dependency>
    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-preferences-backend</artifactId>
    </dependency>
    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-preferences-ui-client</artifactId>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-preferences-client</artifactId>
      <scope>provided</scope>
    </dependency>

    <!-- UberFire Security (Extension) -->
    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-security-api</artifactId>
    </dependency>
    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-security-client</artifactId>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-servlet-security</artifactId>
    </dependency>

    <!-- Uberfire Security Management -->

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-security-management-api</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-security-management-backend</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-security-management-wildfly</artifactId>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-security-management-client</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-widgets-security-management</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.uberfire</groupId>
      <artifactId>uberfire-security-management-client-wb</artifactId>
      <scope>provided</scope>
    </dependency>

    <!-- Log -->

    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-ext</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>log4j-over-slf4j</artifactId>
    </dependency>

    <!-- Errai -->

    <dependency>
      <groupId>org.jboss.errai</groupId>
      <artifactId>errai-common</artifactId>
    </dependency>

    <dependency>
      <groupId>org.jboss.errai</groupId>
      <artifactId>errai-marshalling</artifactId>
    </dependency>

    <dependency>
      <groupId>de.benediktmeurer.gwt-slf4j</groupId>
      <artifactId>gwt-slf4j</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.jboss.errai</groupId>
      <artifactId>errai-ui</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.jboss.errai</groupId>
      <artifactId>errai-ioc</artifactId>
    </dependency>

    <dependency>
      <groupId>org.jboss.errai</groupId>
      <artifactId>errai-security-server</artifactId>
    </dependency>

    <dependency>
      <groupId>org.jboss.errai</groupId>
      <artifactId>errai-security-client</artifactId>
      <scope>provided</scope>
      <exclusions>
        <!-- Collides with org.jboss.spec.javax.el:jboss-el-api_2.2_spec -->
        <exclusion>
          <groupId>javax.el</groupId>
          <artifactId>el-api</artifactId>
        </exclusion>
      </exclusions>
    </dependency>

    <dependency>
      <groupId>org.jboss.errai</groupId>
      <artifactId>errai-jboss-as-support</artifactId>
    </dependency>

    <dependency>
      <groupId>org.jboss.errai</groupId>
      <artifactId>errai-javax-enterprise</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.jboss.errai</groupId>
      <artifactId>errai-cdi-server</artifactId>
    </dependency>

    <dependency>
      <groupId>org.owasp.encoder</groupId>
      <artifactId>encoder</artifactId>
    </dependency>

    <dependency>
      <groupId>org.jboss.errai</groupId>
      <artifactId>errai-codegen-gwt</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.jboss.errai</groupId>
      <artifactId>errai-validation</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>javax.validation</groupId>
      <artifactId>validation-api</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>javax.validation</groupId>
      <artifactId>validation-api</artifactId>
      <classifier>sources</classifier>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.hibernate</groupId>
      <artifactId>hibernate-validator</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.hibernate</groupId>
      <artifactId>hibernate-validator</artifactId>
      <scope>provided</scope>
      <classifier>sources</classifier>
    </dependency>

    <!-- Container provided dependencies -->

    <dependency>
      <groupId>javax.enterprise</groupId>
      <artifactId>cdi-api</artifactId>
      <scope>provided</scope>
      <exclusions>
        <!-- Collides with org.jboss.spec.javax.annotation:jboss-annotations-api_1.2_spec -->
        <exclusion>
          <groupId>javax.annotation</groupId>
          <artifactId>jsr250-api</artifactId>
        </exclusion>
      </exclusions>
    </dependency>

    <dependency>
      <groupId>javax.inject</groupId>
      <artifactId>javax.inject</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.jboss.errai</groupId>
      <artifactId>errai-cdi-jboss</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>xml-apis</groupId>
      <artifactId>xml-apis</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>com.sun.xml.bind</groupId>
      <artifactId>jaxb-impl</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.jboss.spec.javax.ws.rs</groupId>
      <artifactId>jboss-jaxrs-api_2.0_spec</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.jboss.resteasy</groupId>
      <artifactId>resteasy-cdi</artifactId>
      <scope>provided</scope>
      <exclusions>
        <exclusion>
          <groupId>javax.annotation</groupId>
          <artifactId>jsr250-api</artifactId>
        </exclusion>
      </exclusions>
    </dependency>

    <dependency>
      <groupId>org.jboss.resteasy</groupId>
      <artifactId>resteasy-jaxrs</artifactId>
      <scope>provided</scope>
      <exclusions>
        <!-- Collides with org.javassist:javassist -->
        <exclusion>
          <groupId>javassist</groupId>
          <artifactId>javassist</artifactId>
        </exclusion>
        <!-- Collides with org.jboss.spec.javax.annotation:jboss-annotations-api_1.2_spec -->
        <exclusion>
          <groupId>javax.annotation</groupId>
          <artifactId>jsr250-api</artifactId>
        </exclusion>
      </exclusions>
    </dependency>

    <!-- GWT and GWT Extensions -->

    <dependency>
      <groupId>com.google.gwt</groupId>
      <artifactId>gwt-user</artifactId>
      <scope>provided</scope>
      <exclusions>
        <exclusion>
          <groupId>javax.servlet</groupId>
          <artifactId>javax.servlet-api</artifactId>
        </exclusion>
      </exclusions>
    </dependency>

    <dependency>
      <groupId>org.gwtbootstrap3</groupId>
      <artifactId>gwtbootstrap3</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.gwtbootstrap3</groupId>
      <artifactId>gwtbootstrap3-extras</artifactId>
      <scope>provided</scope>
    </dependency>

  </dependencies>

  <build>
    <finalName>${project.artifactId}</finalName>
    <outputDirectory>src/main/webapp/WEB-INF/classes</outputDirectory>

    <plugins>

      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>gwt-maven-plugin</artifactId>
        <configuration>
          <deploy>${project.build.directory}/gwt-symbols-deploy</deploy>
          <localWorkers>${gwt.compiler.localWorkers}</localWorkers>
          <module>org.dashbuilder.FastCompiledDashbuilderShowcase</module>
          <draftCompile>true</draftCompile>
          <logLevel>INFO</logLevel>
          <strict>true</strict>
          <compileSourcesArtifacts>

            <!-- Dashbuilder -->
            <compileSourcesArtifact>org.kie.soup:kie-soup-json</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-widgets</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-validations</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-common-client</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-services-api</compileSourcesArtifact>
            <compileSourcesArtifact>org.kie.soup:kie-soup-dataset-api</compileSourcesArtifact>
            <compileSourcesArtifact>org.kie.soup:kie-soup-dataset-shared</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-dataset-client</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-displayer-api</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-displayer-client</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-displayer-screen</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-displayer-editor</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-dataset-editor</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-renderer-default</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-renderer-google</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-renderer-chartjs</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-renderer-lienzo</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-navigation-api</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-navigation-client</compileSourcesArtifact>
            <compileSourcesArtifact>org.dashbuilder:dashbuilder-cms-client</compileSourcesArtifact>

            <!-- Uberfire ext -->
            <compileSourcesArtifact>org.uberfire:uberfire-runtime-plugins-api</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-runtime-plugins-client</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-layout-editor-api</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-layout-editor-client</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-commons-editor-api</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-commons-editor-client</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-widgets-service-api</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-widgets-commons</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-widgets-table</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-widgets-properties-editor-api</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-widgets-properties-editor-client</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-simple-docks-client</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-preferences-api</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-preferences-client</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-preferences-ui-client</compileSourcesArtifact>

            <compileSourcesArtifact>org.kie.soup:kie-soup-commons</compileSourcesArtifact>

            <!-- UberFire -->
            <compileSourcesArtifact>org.uberfire:uberfire-commons</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-nio2-model</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-io</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-api</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-js</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-security-api</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-security-client</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-client-api</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-workbench-client</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-workbench-client-backend</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-workbench-client-views-patternfly</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-backend-api</compileSourcesArtifact>

            <!-- UberFire Security Management -->
            <compileSourcesArtifact>org.uberfire:uberfire-security-management-api</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-security-management-client</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-security-management-client-wb</compileSourcesArtifact>
            <compileSourcesArtifact>org.uberfire:uberfire-widgets-security-management</compileSourcesArtifact>

          </compileSourcesArtifacts>
          <runTarget>dashbuilder.html</runTarget>
          <extraJvmArgs>-Xmx2024m -XX:CompileThreshold=7000 -Derrai.jboss.home=${errai.jboss.home}</extraJvmArgs>
          <noServer>false</noServer>
          <server>org.jboss.errai.cdi.server.gwt.EmbeddedWildFlyLauncher</server>
          <hostedWebapp>src/main/webapp</hostedWebapp>
          <webappDirectory>${project.build.directory}/${project.build.finalName}</webappDirectory>
          <disableCastChecking>true</disableCastChecking>
        </configuration>
        <executions>
          <execution>
            <id>gwt-clean</id>
            <phase>clean</phase>
            <goals>
              <goal>clean</goal>
            </goals>
          </execution>
          <execution>
            <id>gwt-compile</id>
            <goals>
              <goal>resources</goal>
              <goal>compile</goal>
            </goals>
          </execution>
        </executions>
      </plugin>

      <plugin>
        <artifactId>maven-war-plugin</artifactId>
        <configuration>
          <packagingExcludes>**/javax/**/*.*,**/client/**/*.class,**/*.symbolMap</packagingExcludes>
          <archive>
            <addMavenDescriptor>false</addMavenDescriptor>
          </archive>
        </configuration>
      </plugin>

      <plugin>
        <artifactId>maven-clean-plugin</artifactId>
        <configuration>
          <filesets>
            <fileset>
              <directory>${basedir}</directory>
              <includes>
                <include>src/main/webapp/org.dashbuilder.DashbuilderShowcase/</include>
                <include>src/main/webapp/WEB-INF/classes/</include>
                <include>src/main/webapp/WEB-INF/deploy/</include>
                <include>src/main/webapp/WEB-INF/lib/</include>
                <include>**/gwt-unitCache/**</include>
                <include>.errai/</include>
                <include>.niogit/**</include>
                <include>.index/**</include>
              </includes>
            </fileset>
          </filesets>
        </configuration>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-dependency-plugin</artifactId>
        <executions>
          <execution>
            <id>unpack</id>
            <phase>process-resources</phase>
            <goals>
              <goal>unpack</goal>
            </goals>
            <configuration>
              <artifactItems>
                <artifactItem>
                  <groupId>org.jboss.errai</groupId>
                  <artifactId>wildfly-dist</artifactId>
                  <version>${version.org.jboss.errai.wildfly.sdm}</version>
                  <type>zip</type>
                  <overWrite>false</overWrite>
                  <outputDirectory>${project.build.directory}</outputDirectory>
                </artifactItem>
              </artifactItems>
              <skip>${gwt.compiler.skip}</skip>
            </configuration>
          </execution>
        </executions>
      </plugin>

      <plugin>
        <artifactId>maven-resources-plugin</artifactId>
        <version>2.6</version>
        <executions>
          <execution>
            <id>copy-resources</id>
            <phase>process-resources</phase>
            <goals>
              <goal>copy-resources</goal>
            </goals>
            <configuration>
              <outputDirectory>${project.build.directory}/wildfly-${as.version}/standalone/deployments</outputDirectory>
              <resources>
                <resource>
                  <directory>src/test/resources/datasources</directory>
                  <filtering>true</filtering>
                </resource>
              </resources>
            </configuration>
          </execution>
        </executions>
      </plugin>

    </plugins>

  </build>

  <profiles>
    <profile>
      <id>fullProfile</id>
      <activation>
        <property>
          <name>full</name>
        </property>
      </activation>
      <build>
        <plugins>
          <plugin><!-- Keep in sync with soa profile -->
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>gwt-maven-plugin</artifactId>
            <configuration>
              <!-- Build all GWT permutations and optimize them -->
              <module>org.dashbuilder.DashbuilderShowcase</module>
              <draftCompile>false</draftCompile>
              <force>true</force>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
    <!-- profile to disable GWT compilation of showcase (useful in full downstream builds) -->
    <profile>
      <id>no-showcase</id>
      <build>
        <plugins>
          <plugin>
            <groupId>org.codehaus.mojo</groupId>
            <artifactId>gwt-maven-plugin</artifactId>
            <configuration>
              <skip>true</skip>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>

</project>
