[maven-release-plugin] prepare for next development iteration
[cdmlib.git] / cdmlib-remote-webapp / pom.xml
index eab76962d8db29a5e92da6541c213eb3410e394d..b6b2e7759f8593552c1a0c38a7910d2fab01ac76 100644 (file)
@@ -4,8 +4,8 @@
   <parent>
     <artifactId>cdmlib-parent</artifactId>
     <groupId>eu.etaxonomy</groupId>
-    <version>3.3.0-SNAPSHOT</version>
-       <relativePath>../pom.xml</relativePath>
+    <version>3.5.2-SNAPSHOT</version>
+    <relativePath>../pom.xml</relativePath>
   </parent>
 
   <groupId>eu.etaxonomy</groupId>
     </url>
   </scm>
 
+  <profiles>
+    <profile>
+      <id>local-repository</id>
+      <activation>
+        <property>
+          <name>localrepo</name>
+        </property>
+      </activation>
+      <repositories>
+        <repository>
+          <id>EditLocalRepository</id>
+          <url>file://${localrepo}/eu/etaxonomy/</url>
+          <releases>
+            <enabled>false</enabled>
+            <updatePolicy>always</updatePolicy>
+          </releases>
+          <snapshots>
+            <enabled>true</enabled>
+            <updatePolicy>always</updatePolicy>
+          </snapshots>
+        </repository>
+      </repositories>
+    </profile>
+  </profiles>
+
   <dependencies>
     <dependency>
       <groupId>eu.etaxonomy</groupId>
       <artifactId>cdmlib-remote</artifactId>
     </dependency>
-      <dependency>
-       <!-- TODO this is also offered by cdmlib-remote, can it be removed? What does provided mean? -->
-        <groupId>javax.servlet</groupId>
-        <artifactId>servlet-api</artifactId>
-        <scope>provided</scope>
-      </dependency>
-
-      <dependency>
-        <groupId>org.easymock</groupId>
-        <artifactId>easymock</artifactId>
-      </dependency>
-      <dependency>
-        <groupId>xmlunit</groupId>
-        <artifactId>xmlunit</artifactId>
-      </dependency>
+    <dependency>
+      <!-- TODO this is also offered by cdmlib-remote, can it be removed?
+        What does provided mean? -->
+      <groupId>javax.servlet</groupId>
+      <artifactId>javax.servlet-api</artifactId>
+      <scope>provided</scope>
+    </dependency>
 
-      <dependency>
-        <groupId>commons-io</groupId>
-        <artifactId>commons-io</artifactId>
-      </dependency>
-      <!-- JsonView -->
-      <dependency>
-        <!--  TODO can this be removed, it already exists in cdmlib-remote -->
-        <groupId>net.sf.json-lib</groupId>
-        <artifactId>json-lib</artifactId>
-        <classifier>jdk15</classifier>
-      </dependency>
+    <dependency>
+      <groupId>xmlunit</groupId>
+      <artifactId>xmlunit</artifactId>
+    </dependency>
 
-      <!-- Profiling -->
-      <dependency>
-        <groupId>org.springframework</groupId>
-        <artifactId>org.springframework.oxm</artifactId>
-        <version>${spring.version}</version>
-      </dependency>
-      
-      <!-- XmlView -->
-      <dependency>
-        <groupId>com.thoughtworks.xstream</groupId>
-        <artifactId>xstream</artifactId>
-      </dependency>
-      <dependency>
-        <groupId>xpp3</groupId>
-        <artifactId>xpp3</artifactId>
-      </dependency>
-      <dependency>
-        <groupId>stax</groupId>
-        <artifactId>stax</artifactId>
-      </dependency>
-      
-      <!-- JSP TAG LIBS -->
-      <dependency>
-        <groupId>taglibs</groupId>
-        <artifactId>standard</artifactId>
-        <version>1.1.2</version>
-      </dependency>
-      <dependency>
-        <groupId>taglibs</groupId>
-        <artifactId>x</artifactId>
-        <version>1.1.2</version>
-        <type>tld</type>
-      </dependency>
-      <!--  Connection Pooling  -->
-      <dependency> 
-        <groupId>org.hibernate</groupId> 
-        <artifactId>hibernate-c3p0</artifactId>         
-      </dependency>
-      
-      <dependency>
-       <groupId>com.vaadin</groupId>
-       <artifactId>vaadin-server</artifactId>
-      </dependency>
-      <dependency>
-       <groupId>com.vaadin</groupId>
-       <artifactId>vaadin-shared</artifactId>  
-      </dependency>
-      <dependency>
-       <groupId>com.vaadin</groupId>
-       <artifactId>vaadin-client-compiled</artifactId>
-      </dependency>
-      <dependency>
-       <groupId>com.vaadin</groupId>
-       <artifactId>vaadin-client</artifactId>
-       <scope>provided</scope>
-      </dependency>
-      <dependency>
-       <groupId>com.vaadin</groupId>
-       <artifactId>vaadin-themes</artifactId>
-      </dependency>
-      <dependency>
-       <groupId>com.vaadin</groupId>
-       <artifactId>vaadin-client-compiler</artifactId> 
-      </dependency>
+    <dependency>
+      <groupId>commons-io</groupId>
+      <artifactId>commons-io</artifactId>
+    </dependency>
+    <!-- JsonView -->
+    <dependency>
+      <!-- TODO can this be removed, it already exists in cdmlib-remote -->
+      <groupId>net.sf.json-lib</groupId>
+      <artifactId>json-lib</artifactId>
+      <classifier>jdk15</classifier>
+    </dependency>
 
-      <dependency>
-       <groupId>ru.xpoft.vaadin</groupId>
-       <artifactId>spring-vaadin-integration</artifactId>
-      </dependency>
+    <!-- Profiling -->
+    <dependency>
+      <groupId>org.springframework</groupId>
+      <artifactId>org.springframework.oxm</artifactId>
+      <version>${spring.version}</version>
+    </dependency>
 
-      <dependency>
-       <groupId>org.vaadin.addons</groupId>
-       <artifactId>exporter</artifactId>
-      </dependency>
-       
-      <dependency>
-       <groupId>org.vaadin.addons</groupId>
-       <artifactId>wizards-for-vaadin</artifactId>
-      </dependency>
+    <!-- XmlView -->
+    <dependency>
+      <groupId>com.thoughtworks.xstream</groupId>
+      <artifactId>xstream</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>xpp3</groupId>
+      <artifactId>xpp3</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>stax</groupId>
+      <artifactId>stax</artifactId>
+    </dependency>
 
-      <!--  SQL Profiling  -->
-      <dependency>
-        <groupId>p6spy</groupId>
-        <artifactId>p6spy</artifactId>
-        <version>1.3</version>
-      </dependency>
-    
+    <!-- JSP TAG LIBS -->
+    <dependency>
+      <groupId>taglibs</groupId>
+      <artifactId>standard</artifactId>
+      <version>1.1.2</version>
+    </dependency>
+    <dependency>
+      <groupId>taglibs</groupId>
+      <artifactId>x</artifactId>
+      <version>1.1.2</version>
+      <type>tld</type>
+    </dependency>
+    <!-- Connection Pooling -->
+    <dependency>
+      <groupId>org.hibernate</groupId>
+      <artifactId>hibernate-c3p0</artifactId>
+    </dependency>
+    <!-- swagger -->
+    <dependency>
+      <groupId>com.mangofactory</groupId>
+      <artifactId>swagger-springmvc</artifactId>
+      <version>0.8.5</version>
+    </dependency>
+    <!-- dependencies for swagger-springmvc, added explicitely -->
+    <dependency>
+      <groupId>com.fasterxml.jackson.core</groupId>
+      <artifactId>jackson-databind</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>com.fasterxml.jackson.core</groupId>
+      <artifactId>jackson-core</artifactId>
+    </dependency>
     <dependency>
+      <groupId>com.fasterxml.jackson.core</groupId>
+      <artifactId>jackson-annotations</artifactId>
+    </dependency>
+    <!-- END of dependencies for swagger-springmvc, added explicitely -->
+    <!-- testing -->
+  <dependency>
       <groupId>junit</groupId>
       <artifactId>junit</artifactId>
-      <version>3.8.1</version>
       <scope>test</scope>
     </dependency>
     <dependency>
-        <groupId>com.yourkit</groupId>
-        <artifactId>yjp-controller-api-redist</artifactId>
-        <scope>test</scope>
+      <groupId>com.yourkit</groupId>
+      <artifactId>yjp-controller-api-redist</artifactId>
+      <scope>test</scope>
     </dependency>
-
   </dependencies>
 
-    <build>
-      <!-- Configure the webapp -->
-      <finalName>cdmserver</finalName>
-      <plugins>
-        <plugin>
-          <groupId>org.apache.maven.plugins</groupId>
-          <artifactId>maven-war-plugin</artifactId>
-          <version>2.1-beta-1</version>
-        </plugin>
-      </plugins>
-    </build>
+  <build>
+    <resources>
+      <!-- ${basedir}/src/test/resources -->
+      <resource>
+        <!-- replace the place holders like ${...} in datasources.xml -->
+        <targetPath>${project.build.directory}/test-classes</targetPath>
+        <filtering>true</filtering>
+        <directory>${basedir}/src/test/resources</directory>
+        <includes>
+          <include>datasources.xml</include>
+        </includes>
+      </resource>
+      <resource>
+        <!-- all other test resources without filtering -->
+        <targetPath>${project.build.directory}/test-classes</targetPath>
+        <directory>${basedir}/src/test/resources</directory>
+        <excludes>
+          <exclude>datasources.xml</exclude>
+        </excludes>
+      </resource>
+      <resource>
+        <!-- all main resources without filtering -->
+        <targetPath>${project.build.directory}/classes</targetPath>
+        <directory>${basedir}/src/main/resources</directory>
+      </resource>
+    </resources>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-war-plugin</artifactId>
+        <version>2.3</version>
+        <configuration>
+          <webResources>
+            <resource>
+              <!-- this is relative to the pom.xml directory -->
+              <directory>${project.build.directory}/cdm-vaadin</directory>
+            </resource>
+          </webResources>
+        </configuration>
+      </plugin>
+      <plugin>
+        <artifactId>maven-failsafe-plugin</artifactId>
+        <version>2.16</version>
+        <configuration>
+          <forkCount>3</forkCount>
+          <reuseForks>true</reuseForks>
+        </configuration>
+        <executions>
+          <execution>
+            <goals>
+              <goal>integration-test</goal>
+              <goal>verify</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+      <plugin>
+        <groupId>org.eclipse.jetty</groupId>
+        <artifactId>jetty-maven-plugin</artifactId>
+        <version>9.1.3.v20140225</version>
+        <configuration>
+          <stopKey>stop</stopKey>
+          <stopPort>9199</stopPort>
+          <scanIntervalSeconds>10</scanIntervalSeconds>
+          <jettyXml>${basedir}/src/test/resources/etc/jetty/jetty.xml,${basedir}/src/test/resources/etc/jetty/jetty-http.xml</jettyXml>
+          <!-- <jettyXml>./src/test/resources/etc/jetty/jetty.xml,./src/test/resources/etc/jetty/jetty-http.xml,./src/test/resources/etc/jetty/jetty-ssl.xml,./src/test/resources/etc/jetty/jetty-https.xml</jettyXml> -->
+          <systemProperties>
+            <systemProperty>
+              <name>cdm.datasource</name>
+              <value>h2_cdmTest</value>
+            </systemProperty>
+            <systemProperty>
+              <!-- datasources.xml is prepared by <plugins><resources>..</resources>
+                above -->
+              <name>cdm.beanDefinitionFile</name>
+              <value>${project.build.directory}/test-classes/datasources.xml</value>
+            </systemProperty>
+          </systemProperties>
+        </configuration>
+        <executions>
+          <execution>
+            <id>start-jetty</id>
+            <phase>pre-integration-test</phase>
+            <goals>
+              <goal>start</goal>
+            </goals>
+            <configuration>
+              <scanIntervalSeconds>0</scanIntervalSeconds>
+              <daemon>true</daemon>
+            </configuration>
+          </execution>
+          <execution>
+            <id>stop-jetty</id>
+            <phase>post-integration-test</phase>
+            <goals>
+              <goal>stop</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-dependency-plugin</artifactId>
+        <version>2.9</version>
+        <executions>
+          <execution>
+            <id>unpack</id>
+            <phase>prepare-package</phase>
+            <goals>
+              <goal>unpack</goal>
+            </goals>
+            <configuration>
+              <artifactItems>
+                <artifactItem>
+                  <groupId>eu.etaxonomy</groupId>
+                  <artifactId>cdm-vaadin</artifactId>
+                  <version>${cdm-vaadin.version}</version>
+                  <type>war</type>
+                  <overWrite>true</overWrite>
+                  <outputDirectory>${project.build.directory}/cdm-vaadin</outputDirectory>
+                  <!-- <destFileName>optional-new-name.jar</destFileName> -->
+                  <!-- <includes>**/*.class,**/*.xml</includes> -->
+                  <excludes>META-INF/**</excludes>
+                </artifactItem>
+              </artifactItems>
+              <!-- <includes>**/*.java</includes> -->
+              <!-- <excludes>**/*.properties</excludes> -->
+              <!-- <outputDirectory>${project.build.directory}/wars</outputDirectory> -->
+              <overWriteReleases>false</overWriteReleases>
+              <overWriteSnapshots>true</overWriteSnapshots>
+            </configuration>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+  </build>
 </project>