changeset 4065:9d404069f361

Added build script for FLYS release.
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Tue, 09 Oct 2012 12:30:13 +0200
parents 61020a61ed38
children f02aa4ff3c0f
files contrib/make_flys_release/README contrib/make_flys_release/bin/run.sh contrib/make_flys_release/bin/wsplgen.exe contrib/make_flys_release/confs/artifact-db.xml contrib/make_flys_release/confs/backend-db.xml contrib/make_flys_release/confs/datacage-db.xml contrib/make_flys_release/confs/floodmap.xml contrib/make_flys_release/confs/log4j.properties contrib/make_flys_release/confs/rest-server.xml contrib/make_flys_release/confs/seddb-db.xml contrib/make_flys_release/confs/web.xml contrib/make_flys_release/h2/artifact-database-1.0-SNAPSHOT.jar contrib/make_flys_release/h2/artifacts-common-1.0-SNAPSHOT.jar contrib/make_flys_release/h2/artifacts-h2.sql contrib/make_flys_release/h2/commons-dbcp-1.2.2.jar contrib/make_flys_release/h2/commons-pool-1.3.jar contrib/make_flys_release/h2/createArtifacts.sh contrib/make_flys_release/h2/createDatacage.sh contrib/make_flys_release/h2/datacage.sql contrib/make_flys_release/h2/h2-1.3.158.jar contrib/make_flys_release/h2/log4j-1.2.14.jar contrib/make_flys_release/libs contrib/make_flys_release/libs_oracle/ojdbc5.jar contrib/make_flys_release/libs_postgresql/hibernate-spatial-postgis-1.1.jar contrib/make_flys_release/libs_postgresql/postgis-jdbc-1.3.3.jar contrib/make_flys_release/libs_postgresql/postgis-stubs-1.3.3.jar contrib/make_flys_release/libs_postgresql/postgresql-8.4-702.jdbc4.jar contrib/make_flys_release/make_release.sh
diffstat 28 files changed, 1026 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/README	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,40 @@
+Konfiguration:
+==============
+Im `confs` Verzeichnis liegen Konfigurationsdateien, die für jede FLYS
+Installation angepasst werden müssen (Ports, Hosts, Datenbank-Connection, etc).
+
+In der `make_flys_release.sh` kann über die Variable `RELEASE` ein TAG aus dem
+HG Repository ausgewählt werden, welches für den Bau von FLYS verwendet werden
+soll.
+
+Außerdem muss in der `make_flys_release` eingestellt werden, ob man FLYS für
+eine Oracle oder Postgresql Datenbank bauen will. Im Verzeichnis sind
+spezifische Libraries im `libs_oracle` und `libs_postgresql` Verzeichnis
+enthalten. In der `make_flys_release` muss zurzeit in Zeile 71-77 eingestellt
+werden, welche Libs (Oracle / Postgresql) wieder aus dem Zielverzeichnis
+entfernt werden sollen.
+
+TODOS:
+======
+- auf return Codes der einzelnen Aufrufe (mvn package, etc) reagieren, und den
+  Bau ggf abbrechen
+- Konfig-Option für den Bau für Oracle und Postgresql integrieren.
+- Libs für Postgresql / Oracle besser in den Build-Prozess integrieren
+
+Prozess:
+========
+Nachdem die Konfigurationen angepasst wurden, kann das Skript mittels
+  sh make_release.sh
+von der Konsole gestartet werden. Anschließend werden die Quellen des
+dive4elements, des HTTP-Clients und von FLYS über SSH aus dem HG Repository
+ausgecheckt. In der `make_flys_release.sh` ist dazu der Name des HG Users in der
+zweiten Zeile anzupassen. Die Quellen werden anschließend mit Maven gebaut.
+
+Für den Client wird OpenLayers-2.11 heruntergeladen und in den Client
+verschoben. Zurzeit wird das komplette OpenLayers-2.11 Verzeichnis in den Client
+verschoben. Dies ist jedoch nur für die Entwicklung sinnvoll.
+
+Das Resultat des Skripts ist ein tar.gz, welches zwei Verzeichnisses beinhaltet:
+`server` und `client`. Im Server sind alle Konfigurationen sowie notwendige
+Bibliotheken zum Starten des FLYS Servers enthalten. Im Client ist lediglich das
+WAR Archiv für einen Servlet Container (z.B. Tomcat) enthalten.
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/bin/run.sh	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,26 @@
+#!/bin/bash
+
+APP=de.intevation.artifactdatabase.App
+
+DIR=`dirname $0`/..
+DIR=`readlink -f "$DIR"`
+
+CLASSPATH=
+for l in `find "$DIR/bin/lib" -name \*.jar -print`; do
+   CLASSPATH=$CLASSPATH:$l
+done
+
+export CLASSPATH
+
+exec java -Xmx256m \
+     -server \
+     -Dflys.datacage.recommendations.development=true \
+     -Dcom.sun.management.jmxremote.port=1229 \
+     -Dcom.sun.management.jmxremote.authenticate=false \
+     -Djava.io.tmpdir="$DIR/cache" \
+     -Dflys.backend.enablejmx=true \
+     -Dflys.uesk.keep.artifactsdir=false \
+     -Dwsplgen.bin.path="$DIR/bin/wsplgen.exe" \
+     -Dwsplgen.log.output=false \
+     -Dartifact.database.dir="$DIR/conf" \
+     $APP
Binary file contrib/make_flys_release/bin/wsplgen.exe has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/confs/artifact-db.xml	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<database>
+    <user>SA</user>
+    <password></password>
+    <url>jdbc:h2:${artifacts.config.dir}/../artifactsdb/artifacts</url>
+</database>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/confs/backend-db.xml	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,18 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<backend-database>
+
+    <user>flys29</user>
+    	<password>flys29</password>
+    	<dialect>org.hibernate.dialect.PostgreSQLDialect</dialect>
+    	<driver>org.postgresql.Driver</driver>
+    <url>jdbc:postgresql://czech-republic.atlas.intevation.de:5432/flys29</url>
+
+    <!--
+	<user>flys27</user>
+	<password>flys27</password>
+	<dialect>org.hibernatespatial.oracle.OracleSpatial10gDialect</dialect>
+	<driver>oracle.jdbc.driver.OracleDriver</driver>
+	<url>jdbc:oracle:thin:@//czech-republic.atlas.intevation.de:1521/XE</url>
+    -->
+
+</backend-database>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/confs/datacage-db.xml	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<datacage>
+    <user>SA</user>
+    <password></password>
+    <url>jdbc:h2:${artifacts.config.dir}/../datacagedb/datacage</url>
+</datacage>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/confs/floodmap.xml	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<floodmap>
+    <shapefile-path value="${artifacts.config.dir}/../shapefiles"/>
+    <mapserver>
+        <server path="http://czech-republic.intevation.de/cgi-bin/flys-default"/>
+        <mapfile path="${artifacts.config.dir}/../flys.map"/>
+        <templates path="${artifacts.config.dir}/mapserver/"/>
+        <map-template path="mapfile.vm"/>
+    </mapserver>
+
+    <velocity>
+        <logfile path="${artifacts.config.dir}/../velocity_log.log"/>
+    </velocity>
+
+    <river name="Saar">
+        <srid value="31466"/>
+        <river-wms url="http://czech-republic.intevation.de/cgi-bin/saar-wms"/>
+        <background-wms url="http://osm.wheregroup.com/cgi-bin/osm_basic.xml?" layers="OSM_Basic"/>
+    </river>
+    <river name="Mosel">
+        <srid value="31466"/>
+        <river-wms url="http://czech-republic.intevation.de/cgi-bin/mosel-wms"/>
+        <background-wms url="http://osm.wheregroup.com/cgi-bin/osm_basic.xml?" layers="OSM_Basic"/>
+    </river>
+    <river name="Elbe">
+        <srid value="31467"/>
+        <river-wms url="http://czech-republic.intevation.de/cgi-bin/elbe-wms"/>
+        <background-wms url="http://osm.wheregroup.com/cgi-bin/osm_basic.xml?" layers="OSM_Basic"/>
+    </river>
+</floodmap>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/confs/log4j.properties	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,27 @@
+log4j.rootLogger=DEBUG, FLYS
+
+########## INTERNAL PACKAGES
+log4j.category.de.intevation.artifactdatabase=INFO
+
+########## INTERNAL CLASSES
+log4j.category.de.intevation.artifactdatabase.DatabaseCleaner=INFO
+log4j.category.de.intevation.flys.utils.ThemeUtil=INFO
+
+
+########## EXTERNAL PACKAGES
+log4j.category.org.hibernate=WARN
+log4j.category.net.sf.ehcache=WARN
+log4j.category.org.eclipse=WARN
+log4j.category.org.restlet=INFO
+
+
+########## APPENDER SETTINGS
+log4j.appender.FLYS.layout=org.apache.log4j.PatternLayout
+log4j.appender.FLYS.layout.ConversionPattern=%d{HH:mm:ss} [%t] %-5p %c{1} - %m%n
+
+
+log4j.appender.FLYS=org.apache.log4j.RollingFileAppender
+log4j.appender.FLYS.File=/tmp/flys-server-default.log
+log4j.appender.FLYS.MaxFileSize=5000KB
+log4j.appender.FLYS.MaxBackupIndex=1
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/confs/rest-server.xml	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<rest-server>
+    <!--  The port which the ArtifactDatabase (ArtifactServer) will bind to. -->
+    <port>8999</port>
+    <listen>localhost</listen>
+</rest-server>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/confs/seddb-db.xml	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<seddb-database>
+    <!-- This is the default SedDB db configuration. -->
+    <user>seddb</user>
+    <password>seddbpass</password>
+    <dialect>org.hibernatespatial.oracle.OracleSpatial10gDialect</dialect>
+    <driver>oracle.jdbc.driver.OracleDriver</driver>
+    <url>jdbc:oracle:thin:@//czech-republic.atlas.intevation.de:1521/XE</url>
+</seddb-database>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/confs/web.xml	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,558 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE web-app
+    PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
+    "http://java.sun.com/dtd/web-app_2_3.dtd">
+
+<web-app>
+
+    <context-param>
+        <param-name>server-url</param-name>
+        <param-value>http://localhost:8999</param-value>
+    </context-param>
+
+    <context-param>
+        <param-name>authentication</param-name>
+        <param-value>GGInA</param-value>
+    </context-param>
+
+    <context-param>
+        <param-name>features-file</param-name>
+        <param-value>/WEB-INF/features.xml</param-value>
+    </context-param>
+
+    <context-param>
+        <param-name>log4j-properties</param-name>
+        <param-value>/WEB-INF/log4j.properties</param-value>
+    </context-param>
+
+    <listener>
+        <listener-class>de.intevation.flys.client.server.BaseServletContextListener</listener-class>
+    </listener>
+
+
+  <!-- Servlets -->
+  <servlet>
+    <servlet-name>user</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.UserServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>user</servlet-name>
+    <url-pattern>/flys/user</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>artifact</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.ArtifactServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>artifact</servlet-name>
+    <url-pattern>/flys/artifact</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>getartifact</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.GetArtifactServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>getartifact</servlet-name>
+    <url-pattern>/flys/getartifact</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>cross-section-km</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.CrossSectionKMServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>cross-section-km</servlet-name>
+    <url-pattern>/flys/cross-section-km</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>create-collection</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.CreateCollectionServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>create-collection</servlet-name>
+    <url-pattern>/flys/create-collection</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>rivers</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.RiverServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>rivers</servlet-name>
+    <url-pattern>/flys/rivers</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>gaugeoverviewinfo</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.GaugeOverviewInfoServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>gaugeoverviewinfo</servlet-name>
+    <url-pattern>/flys/gaugeoverviewinfo</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>forward</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.StepForwardServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>forward</servlet-name>
+    <url-pattern>/flys/forward</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>feed</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.FeedServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>feed</servlet-name>
+    <url-pattern>/flys/feed</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>fixings-overview</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.FixingsOverviewServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>fixings-overview</servlet-name>
+    <url-pattern>/flys/fixings-overview</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>advance</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.AdvanceServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>advance</servlet-name>
+    <url-pattern>/flys/advance</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>add-artifact</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.AddArtifactServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>add-artifact</servlet-name>
+    <url-pattern>/flys/add-artifact</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>load-artifact</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.LoadArtifactServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>load-artifact</servlet-name>
+    <url-pattern>/flys/load-artifact</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>describe-collection</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.DescribeCollectionServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>describe-collection</servlet-name>
+    <url-pattern>/flys/describe-collection</url-pattern>
+  </servlet-mapping>
+
+    <servlet>
+    <servlet-name>user-collections</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.UserCollectionsServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>user-collections</servlet-name>
+    <url-pattern>/flys/user-collections</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>distanceinfo</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.DistanceInfoServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>distanceinfo</servlet-name>
+    <url-pattern>/flys/distanceinfo</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>dischargeinfo</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.DischargeInfoServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>dischargeinfo</servlet-name>
+    <url-pattern>/flys/dischargeinfo</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>DischargeInfoXML</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.DischargeInfoXML</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>DischargeInfoXML</servlet-name>
+    <url-pattern>/flys/dischargeinfoxml</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>meta-data</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.MetaDataServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>meta-data</servlet-name>
+    <url-pattern>/flys/meta-data</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>mainvalues</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.WQInfoServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>mainvalues</servlet-name>
+    <url-pattern>/flys/mainvalues</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>gaugeinfo</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.GaugeInfoServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>gaugeinfo</servlet-name>
+    <url-pattern>/flys/gaugeinfo</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>csv</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.CSVExportServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>csv</servlet-name>
+    <url-pattern>/flys/csv</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>ChartOutputService</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.ChartOutputServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>ChartOutputService</servlet-name>
+    <url-pattern>/flys/chart</url-pattern>
+  </servlet-mapping>
+
+  <!-- MapFish Print -->
+  <servlet>
+    <servlet-name>MapOutputService</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.MapOutputServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>MapOutputService</servlet-name>
+    <url-pattern>/flys/map</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>mapfish.print</servlet-name>
+    <servlet-class>org.mapfish.print.servlet.MapPrinterServlet</servlet-class>
+    <init-param>
+      <param-name>config</param-name>
+      <param-value>WEB-INF/config.yaml</param-value>
+    </init-param>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>mapfish.print</servlet-name>
+    <url-pattern>/flys/mapfish-print/*</url-pattern>
+  </servlet-mapping>
+
+  <!-- Servlet to bridge between MapFish Print and FLYS3 -->
+  <servlet>
+    <servlet-name>MapPrintService</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.MapPrintServiceImpl</servlet-class>
+    <init-param>
+      <param-name>config</param-name>
+      <param-value>WEB-INF/config.yaml</param-value>
+    </init-param>
+    <init-param>
+      <param-name>print-url</param-name>
+      <param-value>http://localhost:8888/flys/mapfish-print</param-value>
+    </init-param>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>MapPrintService</servlet-name>
+    <url-pattern>/flys/map-print</url-pattern>
+  </servlet-mapping>
+
+
+  <servlet>
+    <servlet-name>FixingsKMChartService</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.FixingsKMChartServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>FixingsKMChartService</servlet-name>
+    <url-pattern>/flys/fixings-km-chart</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>DistanceInfoXML</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.DistanceInfoXML</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>DistanceInfoXML</servlet-name>
+    <url-pattern>/flys/distanceinfoxml</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>ExportService</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.ExportServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>ExportService</servlet-name>
+    <url-pattern>/flys/export</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>CollectionAttributeService</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.CollectionAttributeServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>CollectionAttributeService</servlet-name>
+    <url-pattern>/flys/collection-attribute</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>CollectionItemAttributeService</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.CollectionItemAttributeServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>CollectionItemAttributeService</servlet-name>
+    <url-pattern>/flys/collection-item-attribute</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>ChartInfoService</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.ChartInfoServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>ChartInfoService</servlet-name>
+    <url-pattern>/flys/chart-info</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>ReportService</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.ReportServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>ReportService</servlet-name>
+    <url-pattern>/flys/report</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>SetCollectionNameService</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.SetCollectionNameServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>SetCollectionNameService</servlet-name>
+    <url-pattern>/flys/set-collectionname</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>SetCollectionTTLService</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.SetCollectionTTLServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>SetCollectionTTLService</servlet-name>
+    <url-pattern>/flys/set-collectionttl</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>DeleteCollectionService</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.DeleteCollectionServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>DeleteCollectionService</servlet-name>
+    <url-pattern>/flys/delete-collection</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>MapInfoService</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.MapInfoServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>MapInfoService</servlet-name>
+    <url-pattern>/flys/map-info</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>getfeatureinfo</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.GFIServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>getfeatureinfo</servlet-name>
+    <url-pattern>/flys/getfeatureinfo</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>getcapabilities</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.GCServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>getcapabilities</servlet-name>
+    <url-pattern>/flys/getcapabilities</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>DescribeArtifactService</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.DescribeArtifactServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>DescribeArtifactService</servlet-name>
+    <url-pattern>/flys/describe</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>remove-artifact</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.RemoveArtifactServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>remove-artifact</servlet-name>
+    <url-pattern>/flys/remove-artifact</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>GetWMSUrls</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.MapUrlServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>GetWMSUrls</servlet-name>
+    <url-pattern>/flys/map-urls</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>FileUpload</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.FileUploadServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>FileUpload</servlet-name>
+    <url-pattern>/flys/fileupload</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>themelisting</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.ThemeListingServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>themelisting</servlet-name>
+    <url-pattern>/flys/themelisting</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>SQKMChart</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.SQKMChartServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>SQKMChart</servlet-name>
+    <url-pattern>/flys/sq-km-chart</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>BedKMChart</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.BedKMChartServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>BedKMChart</servlet-name>
+    <url-pattern>/flys/bed-km-chart</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>BedloadKMChart</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.BedloadKMChartServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>BedloadKMChart</servlet-name>
+    <url-pattern>/flys/bedload-km-chart</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>login</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.LoginServlet</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>login</servlet-name>
+    <url-pattern>/flys/login</url-pattern>
+  </servlet-mapping>
+
+  <servlet>
+    <servlet-name>modules</servlet-name>
+    <servlet-class>de.intevation.flys.client.server.ModuleServiceImpl</servlet-class>
+  </servlet>
+
+  <servlet-mapping>
+    <servlet-name>modules</servlet-name>
+    <url-pattern>/flys/modules</url-pattern>
+  </servlet-mapping>
+
+  <filter>
+    <filter-name>GGInAFilter</filter-name>
+    <filter-class>de.intevation.flys.client.server.GGInAFilter</filter-class>
+    <init-param>
+        <param-name>deactivate</param-name>
+        <param-value>false</param-value>
+    </init-param>
+  </filter>
+
+  <filter-mapping>
+    <filter-name>GGInAFilter</filter-name>
+    <url-pattern>/*</url-pattern>
+  </filter-mapping>
+
+  <!-- Default page to serve -->
+  <welcome-file-list>
+    <welcome-file>FLYS.html</welcome-file>
+  </welcome-file-list>
+
+</web-app>
Binary file contrib/make_flys_release/h2/artifact-database-1.0-SNAPSHOT.jar has changed
Binary file contrib/make_flys_release/h2/artifacts-common-1.0-SNAPSHOT.jar has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/h2/artifacts-h2.sql	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,59 @@
+--
+-- schema to store artifacts in H2 databases.
+--
+
+BEGIN;
+
+-- not using AUTO_INCREMENT to be more compatible with
+-- other dbms.
+CREATE SEQUENCE ARTIFACTS_ID_SEQ;
+
+CREATE TABLE artifacts (
+    id          INT PRIMARY KEY NOT NULL,
+    gid         UUID            NOT NULL UNIQUE,
+    creation    TIMESTAMP       NOT NULL,
+    last_access TIMESTAMP       NOT NULL,
+    ttl         BIGINT, -- NULL means eternal
+    factory     VARCHAR(256)    NOT NULL,
+    data        BINARY
+);
+
+CREATE SEQUENCE USERS_ID_SEQ;
+
+CREATE TABLE users (
+    id   INT PRIMARY KEY NOT NULL,
+    gid  UUID            NOT NULL UNIQUE,
+    name VARCHAR(256)    NOT NULL,
+    account VARCHAR(256) NOT NULL UNIQUE,
+    role BINARY
+);
+
+CREATE SEQUENCE COLLECTIONS_ID_SEQ;
+
+CREATE TABLE collections (
+    id          INT PRIMARY KEY NOT NULL,
+    gid         UUID            NOT NULL UNIQUE,
+    name VARCHAR(256)           NOT NULL,
+    owner_id    INT             NOT NULL REFERENCES users(id),
+    creation    TIMESTAMP       NOT NULL,
+    last_access TIMESTAMP       NOT NULL,
+    ttl         BIGINT, -- NULL means eternal
+    attribute   BINARY
+);
+
+CREATE SEQUENCE COLLECTION_ITEMS_ID_SEQ;
+
+CREATE TABLE collection_items (
+    id            INT PRIMARY KEY NOT NULL,
+    collection_id INT             NOT NULL REFERENCES collections(id),
+    artifact_id   INT             NOT NULL REFERENCES artifacts(id),
+    attribute     BINARY,
+    creation      TIMESTAMP       NOT NULL,
+    UNIQUE (collection_id, artifact_id)
+);
+
+CREATE TRIGGER collections_access_update_trigger AFTER UPDATE
+    ON artifacts FOR EACH ROW 
+    CALL "de.intevation.artifactdatabase.h2.CollectionAccessUpdateTrigger";
+
+COMMIT;
Binary file contrib/make_flys_release/h2/commons-dbcp-1.2.2.jar has changed
Binary file contrib/make_flys_release/h2/commons-pool-1.3.jar has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/h2/createArtifacts.sh	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+mkdir artifactsdb
+
+DIR=`dirname $0`
+DIR=`readlink -f "$DIR"`
+
+CLASSPATH=
+for l in `find "$DIR" -name \*.jar -print`; do
+   CLASSPATH=$CLASSPATH:$l
+done
+
+export CLASSPATH
+
+java org.h2.tools.RunScript \
+    -url jdbc:h2:`readlink -f artifactsdb`/artifacts \
+    -script $DIR/artifacts-h2.sql
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/h2/createDatacage.sh	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+mkdir datacagedb
+
+DIR=`dirname $0`
+DIR=`readlink -f "$DIR"`
+
+CLASSPATH=
+for l in `find "$DIR" -name \*.jar -print`; do
+   CLASSPATH=$CLASSPATH:$l
+done
+
+export CLASSPATH
+
+java org.h2.tools.RunScript \
+    -url jdbc:h2:`readlink -f datacagedb`/datacage \
+    -script $DIR/datacage.sql
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/h2/datacage.sql	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,104 @@
+BEGIN;
+
+CREATE SEQUENCE USERS_ID_SEQ;
+
+CREATE TABLE users (
+    id  INT  PRIMARY KEY NOT NULL,
+    gid UUID             NOT NULL UNIQUE
+);
+
+CREATE SEQUENCE COLLECTIONS_ID_SEQ;
+
+CREATE TABLE collections (
+    id       INT  PRIMARY KEY NOT NULL,
+    gid      UUID             NOT NULL UNIQUE,
+    user_id  INT              NOT NULL REFERENCES users(id) ON DELETE CASCADE,
+    name     VARCHAR(256)     NOT NULL,
+    creation TIMESTAMP        NOT NULL
+);
+
+CREATE SEQUENCE ARTIFACTS_ID_SEQ;
+
+CREATE TABLE artifacts (
+    id       INT  PRIMARY KEY NOT NULL,
+    gid      UUID             NOT NULL UNIQUE,
+    state    VARCHAR(256)     NOT NULL,
+    creation TIMESTAMP        NOT NULL
+);
+
+CREATE SEQUENCE COLLECTION_ITEMS_ID_SEQ;
+
+CREATE TABLE collection_items (
+    id            INT PRIMARY KEY NOT NULL,
+    collection_id INT             NOT NULL REFERENCES collections(id) ON DELETE CASCADE,
+    artifact_id   INT             NOT NULL REFERENCES artifacts(id)   ON DELETE CASCADE
+);
+
+CREATE SEQUENCE ARTIFACT_DATA_ID_SEQ;
+
+CREATE TABLE artifact_data (
+    id          INT PRIMARY KEY NOT NULL,
+    artifact_id INT             NOT NULL REFERENCES artifacts(id) ON DELETE CASCADE,
+    kind        VARCHAR(256)    NOT NULL,
+    k           VARCHAR(256)    NOT NULL,
+    v           VARCHAR(256),   -- Maybe too short
+    UNIQUE (artifact_id, k)
+);
+
+CREATE SEQUENCE OUTS_ID_SEQ;
+
+CREATE TABLE outs (
+    id          INT PRIMARY KEY NOT NULL,
+    artifact_id INT             NOT NULL REFERENCES artifacts(id) ON DELETE CASCADE,
+    name        VARCHAR(256)    NOT NULL,
+    description VARCHAR(256),
+    out_type    VARCHAR(256)
+);
+
+CREATE SEQUENCE FACETS_ID_SEQ;
+
+CREATE TABLE facets (
+    id          INT PRIMARY KEY NOT NULL,
+    out_id      INT             NOT NULL REFERENCES outs(id) ON DELETE CASCADE,
+    name        VARCHAR(256)    NOT NULL,
+    num         INT             NOT NULL,
+    state       VARCHAR(256)    NOT NULL,
+    description VARCHAR(256),
+    UNIQUE (out_id, num, name)
+);
+
+CREATE VIEW master_artifacts AS
+    SELECT a2.id             AS id,
+           a2.gid            AS gid,
+           a2.state          AS state,
+           a2.creation       AS creation,
+           ci2.collection_id AS collection_id
+    FROM   collection_items ci2 
+           JOIN artifacts a2 
+             ON ci2.artifact_id = a2.id 
+           JOIN (SELECT ci.collection_id AS c_id, 
+                        MIN(a.creation)  AS oldest_a 
+                 FROM   collection_items ci 
+                        JOIN artifacts a 
+                          ON ci.artifact_id = a.id 
+                 GROUP  BY ci.collection_id) o 
+             ON o.c_id = ci2.collection_id 
+    WHERE  a2.creation = o.oldest_a;
+
+-- DROP VIEW master_artifacts;
+-- DROP SEQUENCE USERS_ID_SEQ;
+-- DROP SEQUENCE COLLECTIONS_ID_SEQ;
+-- DROP SEQUENCE ARTIFACTS_ID_SEQ;
+-- DROP SEQUENCE COLLECTION_ITEMS_ID_SEQ;
+-- DROP SEQUENCE ARTIFACT_DATA_ID_SEQ;
+-- DROP SEQUENCE OUTS_ID_SEQ;
+-- DROP SEQUENCE FACETS_ID_SEQ;
+-- DROP TABLE facets;
+-- DROP TABLE outs;
+-- DROP TABLE artifact_data;
+-- DROP TABLE collection_items;
+-- DROP TABLE collections;
+-- DROP TABLE artifacts;
+-- DROP TABLE users;
+
+COMMIT;
Binary file contrib/make_flys_release/h2/h2-1.3.158.jar has changed
Binary file contrib/make_flys_release/h2/log4j-1.2.14.jar has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/libs	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,1 @@
+libs_postgresql
\ No newline at end of file
Binary file contrib/make_flys_release/libs_oracle/ojdbc5.jar has changed
Binary file contrib/make_flys_release/libs_postgresql/hibernate-spatial-postgis-1.1.jar has changed
Binary file contrib/make_flys_release/libs_postgresql/postgis-jdbc-1.3.3.jar has changed
Binary file contrib/make_flys_release/libs_postgresql/postgis-stubs-1.3.3.jar has changed
Binary file contrib/make_flys_release/libs_postgresql/postgresql-8.4-702.jdbc4.jar has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/contrib/make_flys_release/make_release.sh	Tue Oct 09 12:30:13 2012 +0200
@@ -0,0 +1,102 @@
+#!/bin/sh
+HG_USER=YOURNAME
+
+echo "INFO: define required variables"
+ARTIFACTS_HG_REPO="ssh://$HG_USER@hg.wald.intevation.org/hg/dive4elements/artifacts"
+HTTPCLIIENT_HG_REPO="ssh://$HG_USER@hg.wald.intevation.org/hg/dive4elements/http-client"
+FLYS_HG_REPO="ssh://$HG_USER@hg.wald.intevation.org/hg/dive4elements/flys"
+
+ARTIFACTS_HG="hg.artifacts"
+HTTPCLIENT_HG="hg.http-client"
+FLYS_HG="hg.flys"
+
+PREFIX="flys-"
+RELEASE="default"
+DIRECTORY=$PREFIX$RELEASE
+
+echo "INFO: create server directories"
+mkdir $DIRECTORY
+mkdir $DIRECTORY/server
+mkdir $DIRECTORY/server/bin
+mkdir $DIRECTORY/server/bin/lib
+mkdir $DIRECTORY/server/bin/lib/own
+mkdir $DIRECTORY/server/shapefiles
+mkdir $DIRECTORY/client
+
+echo "INFO: checkout sources"
+echo " ... checkout $ARTIFACTS_HG_REPO"
+hg clone $ARTIFACTS_HG_REPO $ARTIFACTS_HG
+(cd $ARTIFACTS_HG && hg co $RELEASE)
+
+echo " ... checkout $HTTPCLIIENT_HG_REPO"
+hg clone $HTTPCLIIENT_HG_REPO $HTTPCLIENT_HG
+(cd $HTTPCLIENT_HG && hg co $RELEASE)
+
+echo " ... checkout $FLYS_HG_REPO"
+hg clone $FLYS_HG_REPO $FLYS_HG
+(cd $FLYS_HG && hg co $RELEASE)
+
+# adapt client configuration
+echo "INFO: prepare configuration of web client"
+cp confs/web.xml $FLYS_HG/flys-client/src/main/webapp/WEB-INF/web.xml
+
+echo "INFO: download OpenLayers-2.11 for client"
+curl -O http://openlayers.org/download/OpenLayers-2.11.tar.gz
+tar xvfz OpenLayers-2.11.tar.gz
+mv OpenLayers-2.11 $FLYS_HG/flys-client/src/main/webapp/
+
+# compile and build our code stuff
+echo "INFO: compile and build sources"
+mvn -f $ARTIFACTS_HG/pom.xml clean compile package
+mvn -f $FLYS_HG/flys-backend/pom.xml clean compile package
+mvn -f $FLYS_HG/flys-artifacts/pom.xml clean compile package dependency:copy-dependencies
+mvn -f $HTTPCLIENT_HG/pom.xml clean compile package install
+mvn -f $FLYS_HG/flys-client/pom.xml clean compile package
+
+## fetch the java stuff
+echo "INFO: copy dependencies and libs"
+cp $ARTIFACTS_HG/artifact-database/target/artifact-database-1.0-SNAPSHOT.jar $DIRECTORY/server/bin/lib/own/
+cp $ARTIFACTS_HG/artifacts/target/artifacts-1.0-SNAPSHOT.jar $DIRECTORY/server/bin/lib/own/
+cp $ARTIFACTS_HG/artifacts-common/target/artifacts-common-1.0-SNAPSHOT.jar $DIRECTORY/server/bin/lib/own/
+cp $FLYS_HG/flys-backend/target/flys-backend-1.0-SNAPSHOT.jar $DIRECTORY/server/bin/lib/own/
+cp $FLYS_HG/flys-artifacts/target/flys-artifacts-1.0-SNAPSHOT.jar $DIRECTORY/server/bin/lib/own/
+cp $FLYS_HG/flys-client/target/FLYS-1.0-SNAPSHOT.war $DIRECTORY/client/
+cp $FLYS_HG/flys-artifacts/target/dependency/* $DIRECTORY/server/bin/lib/
+
+echo "INFO: copy scripts and libraries to target destination"
+cp bin/run.sh $DIRECTORY/server/bin/
+cp bin/wsplgen.exe $DIRECTORY/server/bin/
+cp libs/* $DIRECTORY/server/bin/lib/
+
+#echo "INFO: remove PostgreSQL and PostGIS libraries"
+#rm $DIRECTORY/server/bin/lib/postg*
+#rm $DIRECTORY/server/bin/lib/hibernate-spatial-postgis*
+
+echo "INFO: remove Oralce libraries"
+rm $DIRECTORY/server/bin/lib/hibernate-spatial-oracle-1.1.jar
+rm $DIRECTORY/server/bin/lib/ojdbc*
+
+# fetch the configuration stuff
+echo "INFO: copy default configuration to target destination"
+cp -R $FLYS_HG/flys-artifacts/doc/conf $DIRECTORY/server/
+cp confs/* $DIRECTORY/server/conf/
+
+cp $ARTIFACTS_HG/artifact-database/doc/schema-h2.sql h2/artifacts-h2.sql
+cp $FLYS_HG/flys-artifacts/doc/conf/datacage.sql h2/datacage.sql
+
+echo "INFO: create h2 database for artifacts and datacage"
+h2/createArtifacts.sh
+h2/createDatacage.sh
+
+mv artifactsdb $DIRECTORY/server/
+mv datacagedb $DIRECTORY/server/
+
+echo "INFO: create tarball"
+tar cvfz $DIRECTORY.tar.gz $DIRECTORY
+
+echo "INFO: remove temporary files and directories"
+rm -rf $ARTIFACTS_HG
+rm -rf $HTTPCLIENT_HG
+rm -rf $FLYS_HG
+rm -rf $DIRECTORY
+rm -rf OpenLayers.2.11.tar.gz

http://dive4elements.wald.intevation.org