Mercurial > hg > digilib-old
changeset 899:12b5a3e04b13 mvnify
clean up
author | robcast |
---|---|
date | Wed, 20 Apr 2011 21:40:38 +0200 |
parents | 64f2cb1061a4 |
children | 6c43597b0b08 |
files | client/pom.xml client/src/main/webapp/META-INF/MANIFEST.MF config/build.xml config/tomcat/bin/catalina.sh config/tomcat/bin/rctomcat config/tomcat/conf/server.xml pom.xml servlet/pom.xml servlet/src/META-INF/MANIFEST.MF |
diffstat | 9 files changed, 110 insertions(+), 488 deletions(-) [+] |
line wrap: on
line diff
--- a/client/pom.xml Wed Apr 20 15:25:59 2011 +0200 +++ b/client/pom.xml Wed Apr 20 21:40:38 2011 +0200 @@ -23,7 +23,6 @@ <dependency> <groupId>digilib</groupId> <artifactId>digilib-servlet</artifactId> - <version>2.0-SNAPSHOT</version> <type>jar</type> <scope>compile</scope> </dependency>
--- a/client/src/main/webapp/META-INF/MANIFEST.MF Wed Apr 20 15:25:59 2011 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,3 +0,0 @@ -Manifest-Version: 1.0 -Class-Path: -
--- a/config/build.xml Wed Apr 20 15:25:59 2011 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,93 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<project basedir="." default="build" name="digilib-servlet"> - <property environment="env"/> - <property name="debuglevel" value="source,lines,vars"/> - <property name="target" value="1.4"/> - <property name="source" value="1.4"/> - <path id="digilib.classpath"> - <pathelement location="bin"/> - <fileset dir="lib"> - <include name="**/*.jar"/> - </fileset> - </path> - - <target name="init"> - <tstamp/> - <mkdir dir="bin"/> - <mkdir dir="dist"/> - <available file="servlet/src" property="has.servlet.src"/> - <available file="client/digitallibrary" property="has.webapp.src"/> - </target> - - <target name="clean"> - <delete dir="bin"/> - </target> - - <target name="cleanall" depends="clean"> - <delete dir="client"/> - <delete dir="servlet"/> - </target> - - <target name="build" depends="pkg-servlet,move-servlet"/> - - <target name="dist" depends="build,copy-lib,pkg-webapp"/> - - <target name="dist-nolib" depends="build,pkg-webapp"/> - - <target depends="init,get-src" name="build-servlet"> - <echo message="${ant.project.name}: ${ant.file}"/> - <javac debug="true" debuglevel="${debuglevel}" destdir="bin" source="${source}" target="${target}"> - <src path="servlet/src"/> - <classpath refid="digilib.classpath"/> - </javac> - <!-- Create the time stamp --> - <tstamp/> - </target> - - <target name="pkg-servlet" depends="build-servlet"> - <!-- Put everything in ${build} into the jar file --> - <jar destfile="dist/DigilibServlet-${DSTAMP}.jar" basedir="bin" index="yes"/> - </target> - - <target name="move-servlet" depends="pkg-servlet,get-webapp"> - <!-- put the new jar file in the webapp --> - <copy file="dist/DigilibServlet-${DSTAMP}.jar" - tofile="client/digitallibrary/WEB-INF/lib/DigilibServlet.jar"/> - </target> - - <target name="copy-lib"> - <!-- copy all files in lib in the webapp --> - <copy todir="client/digitallibrary/WEB-INF/lib" includeemptydirs="false"> - <fileset dir="lib"/> - </copy> - </target> - - <target name="pkg-webapp" depends="get-webapp"> - <zip destfile="dist/digilib-${DSTAMP}.zip" basedir="client" /> - </target> - - <target name="get-all" depends="get-src,get-webapp"/> - - <target name="get-src" depends="init" unless="has.servlet.src" - description="download fresh set of sources from CVS"> - <cvs cvsRoot=":pserver:anonymous@cvs.digilib.berlios.de:/cvsroot/digilib" - package="servlet/src" compression="true"/> - </target> - - <target name="get-webapp" depends="init" unless="has.webapp.src" - description="download fresh webapp directory from CVS"> - <cvs cvsRoot=":pserver:anonymous@cvs.digilib.berlios.de:/cvsroot/digilib" - package="client/digitallibrary" compression="true"/> - </target> - - <!-- CVS update should not be needed, checkout is preferrable --> - <target name="update" depends="init,update-src,update-webapp"/> - - <target name="update-src" description="update sources from CVS" > - <cvs dest="servlet/src" command="update" compression="true"/> - </target> - - <target name="update-webapp" description="update webapp from CVS" > - <cvs dest="client/digitallibrary" command="update" compression="true"/> - </target> -</project>
--- a/config/tomcat/bin/catalina.sh Wed Apr 20 15:25:59 2011 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,237 +0,0 @@ -#!/bin/sh -# ----------------------------------------------------------------------------- -# catalina.sh - Start/Stop Script for the CATALINA Server -# -# Environment Variable Prequisites -# -# CATALINA_BASE (Optional) Base directory for resolving dynamic portions -# of a Catalina installation. If not present, resolves to -# the same directory that CATALINA_HOME points to. -# -# CATALINA_HOME (Optional) May point at your Catalina "build" directory. -# If not present, the current working directory is assumed. -# -# CATALINA_OPTS (Optional) Java runtime options used when the "start", -# "stop", or "run" command is executed. -# -# JAVA_HOME Must point at your Java Development Kit installation. -# -# JPDA_OPTS (Optional) Java runtime options used when the "jpda start" -# command is executed. Defaults to -# "-classic -Xdebug -Xnoagent -Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=n" -# -# JSSE_HOME (Optional) May point at your Java Secure Sockets Extension -# (JSSE) installation, whose JAR files will be added to the -# system class path used to start Tomcat. -# -# $Id$ -# ----------------------------------------------------------------------------- - -export JAVA_HOME=/usr/local/lib/IBMJava2-13 -export CATALINA_OPTS="-mx512m" - - -# ----- Verify and Set Required Environment Variables ------------------------- - -if [ -z "$CATALINA_HOME" ] ; then - ## resolve links - $0 may be a link to home - PRG=$0 - progname=`basename $0` - - while [ -h "$PRG" ] ; do - ls=`ls -ld "$PRG"` - link=`expr "$ls" : '.*-> \(.*\)$'` - if expr "$link" : '.*/.*' > /dev/null; then - PRG="$link" - else - PRG="`dirname $PRG`/$link" - fi - done - - CATALINA_HOME_1=`dirname "$PRG"`/.. - echo "Guessing CATALINA_HOME from catalina.sh to ${CATALINA_HOME_1}" - if [ -d ${CATALINA_HOME_1}/conf ] ; then - CATALINA_HOME=${CATALINA_HOME_1} - echo "Setting CATALINA_HOME to $CATALINA_HOME" - fi -fi - -if [ -z "$CATALINA_OPTS" ] ; then - CATALINA_OPTS="" -fi - -if [ -z "$JPDA_OPTS" ] ; then - JPDA_OPTS="-classic -Xdebug -Xnoagent -Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=n" -fi - -if [ -z "$JAVA_HOME" ] ; then - echo You must set JAVA_HOME to point at your Java Development Kit installation - exit 1 -fi - - -# ----- Cygwin Unix Paths Setup ----------------------------------------------- - -# Cygwin support. $cygwin _must_ be set to either true or false. -case "`uname`" in - CYGWIN*) cygwin=true ;; - *) cygwin=false ;; -esac - -# For Cygwin, ensure paths are in UNIX format before anything is touched -if $cygwin ; then - [ -n "$CATALINA_HOME" ] && - CATALINA_HOME=`cygpath --unix "$CATALINA_HOME"` - [ -n "$JAVA_HOME" ] && - JAVA_HOME=`cygpath --unix "$JAVA_HOME"` -fi - - -# ----- Set Up The System Classpath ------------------------------------------- - -CP="$CATALINA_HOME/bin/bootstrap.jar" - -if [ -f "$JAVA_HOME/lib/tools.jar" ] ; then - CP=$CP:"$JAVA_HOME/lib/tools.jar" -fi -if [ -f "$JSSE_HOME/lib/jsse.jar" ] ; then - CP=$CP:"$JSSE_HOME/lib/jcert.jar":"$JSSE_HOME/lib/jnet.jar":"$JSSE_HOME/lib/jsse.jar" -fi - - -# ----- Cygwin Windows Paths Setup -------------------------------------------- - -# convert the existing path to windows -if $cygwin ; then - CP=`cygpath --path --windows "$CP"` - CATALINA_HOME=`cygpath --path --windows "$CATALINA_HOME"` - JAVA_HOME=`cygpath --path --windows "$JAVA_HOME"` -fi - - -# ----- Set Up CATALINA_BASE If Necessary ------------------------------------- - -if [ -z "$CATALINA_BASE" ] ; then - CATALINA_BASE=$CATALINA_HOME -fi - - -# ----- Execute The Requested Command ----------------------------------------- - -echo "Using CLASSPATH: $CP" -echo "Using CATALINA_BASE: $CATALINA_BASE" -echo "Using CATALINA_HOME: $CATALINA_HOME" -echo "Using JAVA_HOME: $JAVA_HOME" - -if [ "$1" = "jpda" ] ; then - CATALINA_OPTS="${CATALINA_OPTS} ${JPDA_OPTS}" - shift -fi - -if [ "$1" = "debug" ] ; then - - shift - if [ "$1" = "-security" ] ; then - shift - $JAVA_HOME/bin/jdb \ - $CATALINA_OPTS \ - -sourcepath $CATALINA_HOME/../../jakarta-tomcat-4.0/catalina/src/share \ - -classpath $CP \ - -Dcatalina.base=$CATALINA_BASE \ - -Dcatalina.home=$CATALINA_HOME \ - org.apache.catalina.startup.Bootstrap "$@" start - else - $JAVA_HOME/bin/jdb \ - $CATALINA_OPTS \ - -sourcepath $CATALINA_HOME/../../jakarta-tomcat-4.0/catalina/src/share \ - -classpath $CP \ - -Dcatalina.base=$CATALINA_BASE \ - -Dcatalina.home=$CATALINA_HOME \ - org.apache.catalina.startup.Bootstrap "$@" start - fi - -elif [ "$1" = "embedded" ] ; then - - shift - for i in ${CATALINA_HOME}/server/lib/*.jar ; do - CP=$i:${CP} - done - for i in ${CATALINA_HOME}/common/lib/*.jar ; do - CP=$i:${CP} - done - echo Embedded Classpath: $CP - $JAVA_HOME/bin/java $CATALINA_OPTS -classpath $CP \ - -Dcatalina.base=$CATALINA_BASE \ - -Dcatalina.home=$CATALINA_HOME \ - org.apache.catalina.startup.Embedded "$@" - -elif [ "$1" = "env" ] ; then - - export BP CATALINA_HOME CP - exit 0 - -elif [ "$1" = "run" ] ; then - - shift - if [ "$1" = "-security" ] ; then - echo Using Security Manager - shift - $JAVA_HOME/bin/java $CATALINA_OPTS -classpath $CP \ - -Djava.security.manager \ - -Djava.security.policy==$CATALINA_BASE/conf/catalina.policy \ - -Dcatalina.base=$CATALINA_BASE \ - -Dcatalina.home=$CATALINA_HOME \ - org.apache.catalina.startup.Bootstrap "$@" start - else - $JAVA_HOME/bin/java $CATALINA_OPTS -classpath $CP \ - -Dcatalina.base=$CATALINA_BASE \ - -Dcatalina.home=$CATALINA_HOME \ - org.apache.catalina.startup.Bootstrap "$@" start - fi - -elif [ "$1" = "start" ] ; then - - shift - touch $CATALINA_BASE/logs/catalina.out - if [ "$1" = "-security" ] ; then - echo Using Security Manager - shift - $JAVA_HOME/bin/java $CATALINA_OPTS -classpath $CP \ - -Djava.security.manager \ - -Djava.security.policy==$CATALINA_BASE/conf/catalina.policy \ - -Dcatalina.base=$CATALINA_BASE \ - -Dcatalina.home=$CATALINA_HOME \ - org.apache.catalina.startup.Bootstrap "$@" start \ - >> $CATALINA_BASE/logs/catalina.out 2>&1 & - else - $JAVA_HOME/bin/java $CATALINA_OPTS -classpath $CP \ - -Dcatalina.base=$CATALINA_BASE \ - -Dcatalina.home=$CATALINA_HOME \ - org.apache.catalina.startup.Bootstrap "$@" start \ - >> $CATALINA_BASE/logs/catalina.out 2>&1 & - fi - -elif [ "$1" = "stop" ] ; then - - shift - $JAVA_HOME/bin/java $CATALINA_OPTS -classpath $CP \ - -Dcatalina.base=$CATALINA_BASE \ - -Dcatalina.home=$CATALINA_HOME \ - org.apache.catalina.startup.Bootstrap "$@" stop - -else - - echo "Usage: catalina.sh ( env | run | start | stop)" - echo "Commands:" - echo " debug Start Catalina in a debugger" - echo " debug -security Debug Catalina with a security manager" - echo " env Set up environment variables that would be used" - echo " jpda start Start Catalina under JPDA debugger" - echo " run Start Catalina in the current window" - echo " run -security Start in the current window with security manager" - echo " start Start Catalina in a separate window" - echo " start -security Start in a separate window with security manager" - echo " stop Stop Catalina" - exit 1 - -fi
--- a/config/tomcat/bin/rctomcat Wed Apr 20 15:25:59 2011 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,87 +0,0 @@ -#! /bin/sh -# - -. /etc/rc.config - -# Determine the base and follow a runlevel link name. -base=${0##*/} -link=${base#*[SK][0-9][0-9]} - -# Force execution if not called by a runlevel directory. -#test $link = $base && START_XNTPD=yes -#test "$START_XNTPD" = yes || exit 0 - -# -# docuservers tomcat (ROC 2.11.01) -# -TOMCATLOG=/usr/local/httpd/logs/tomcat-err.log -TOMCATDIR=/opt/tomcat - -TOMCAT_PID=""; - -function tomcat_runs() { -# we're looking at java vms executing org.apache.catalina.startup.Bootstrap -#ALL_TOMS=$( ps xa | grep org.apache.catalina.startup | grep -v grep ) -#ALL_TOM_IDS=$( echo $ALL_TOMS | cut -d " " -f 1 ) -ALL_TOMS=$( pgrep -u wwwrun java ) -TOMCAT_PID=$( echo $ALL_TOMS | head -1 ) -test -n "$TOMCAT_PID" -} - -return="$rc_done" - -case "$1" in - start) - echo -n "Starting Tomcat Servlet server " - su - wwwrun -c "$TOMCATDIR/bin/startup.sh" >> $TOMCATLOG 2>&1 || return=$rc_failed - echo -e "$return" - ;; - stop) - echo -n "Stopping Tomcat Servlet server " - if su - wwwrun -c "$TOMCATDIR/bin/shutdown.sh" >> $TOMCATLOG 2>&1 - then - for i in 1 2 3 4 5 - do - if tomcat_runs - then - return=$rc_failed - echo -n "." - sleep 2 - else - return=$rc_done - break - fi - done - if tomcat_runs - then - echo -n " killing." - kill $TOMCAT_PID - sleep 2 - fi - if tomcat_runs - then - return=$rc_failed - else - return=$rc_done - fi - else - return=$rc_failed - fi - - echo -e "$return" - ;; - reload|restart) - $0 stop && $0 start || return=$rc_failed - ;; - status) - echo -n "Checking for service tomcat: " - tomcat_runs && echo OK || echo No process - ;; - *) - echo "Usage: $0 {start|stop|status|reload|restart}" - exit 1 -esac - -# Inform the caller not only verbosely and set an exit status. -test "$return" = "$rc_done" || exit 1 -exit 0
--- a/config/tomcat/conf/server.xml Wed Apr 20 15:25:59 2011 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,42 +0,0 @@ -<!-- Digilib Server Configuration File --> - -<Server port="8005" shutdown="SHUTDOWN" debug="0"> - - <!-- Define an Apache-Connector Service --> - <Service name="Tomcat-Docuserver"> - - <!-- Define a non-SSL HTTP/1.1 Connector on port 8080 --> - <Connector className="org.apache.catalina.connector.http.HttpConnector" - port="8080" minProcessors="5" maxProcessors="75" - acceptCount="10" debug="0" connectionTimeout="60000"/> - - <!-- Replace "localhost" with what your Apache "ServerName" is set to --> - <Engine className="org.apache.catalina.connector.warp.WarpEngine" - name="Apache" debug="1" appBase="webapps" defaultHost="hera.unibe.ch"> - - <!-- Global logger unless overridden at lower levels --> - <Logger className="org.apache.catalina.logger.FileLogger" - prefix="apache_log." suffix=".txt" - timestamp="true"/> - - <!-- Define the default virtual host. Hostname must match the engine's. --> - <Host name="hera.unibe.ch" debug="0" appBase="/docuserver/tmp/digilib-test/docuserver"> - - <Context path="/docuserver/digitallibrary" docBase="/docuserver/tmp/digilib-test/docuserver/digitallibrary" debug="0" reloadable="false"> - </Context> - -<!-- - <Context path="/manager" docBase="/opt/tomcat/webapps/manager" debug="0" reloadable="false"> - </Context> ---> - - </Host> - - <!-- Because this Realm is here, an instance will be shared globally --> - <Realm className="org.apache.catalina.realm.MemoryRealm" /> - - </Engine> - - </Service> - -</Server>
--- a/pom.xml Wed Apr 20 15:25:59 2011 +0200 +++ b/pom.xml Wed Apr 20 21:40:38 2011 +0200 @@ -8,12 +8,116 @@ <packaging>pom</packaging> <name>digilib</name> + <description>The Digital Image Library</description> <url>http://digilib.berlios.de</url> + <repositories> + <repository> + <id>itextpdf.com</id> + <name>Maven Repository for iText</name> + <url>http://maven.itextpdf.com/</url> + </repository> + <!-- This provides the required versions of JAI-ImageIO --> + <repository> + <id>geotools.osgeo.org</id> + <name>Geotools repository</name> + <url>http://download.osgeo.org/webdav/geotools/</url> + </repository> + </repositories> + + <dependencyManagement> + <dependencies> + <dependency> + <groupId>digilib</groupId> + <artifactId>digilib-servlet</artifactId> + <version>2.0-SNAPSHOT</version> + <type>jar</type> + <scope>compile</scope> + </dependency> + <dependency> + <groupId>digilib</groupId> + <artifactId>digilib-webapp</artifactId> + <version>2.0-SNAPSHOT</version> + <type>war</type> + <scope>compile</scope> + </dependency> + <dependency> + <groupId>javax.media</groupId> + <artifactId>jai_imageio</artifactId> + <version>1.1</version> + </dependency> + <dependency> + <groupId>javax.media</groupId> + <artifactId>jai_codec</artifactId> + <version>1.1.3</version> + </dependency> + <dependency> + <groupId>javax.media</groupId> + <artifactId>jai_core</artifactId> + <version>1.1.3</version> + </dependency> + <dependency> + <groupId>org.devlib.schmidt</groupId> + <artifactId>imageinfo</artifactId> + <version>1.9</version> + <type>jar</type> + <scope>compile</scope> + </dependency> + <dependency> + <groupId>org.jdom</groupId> + <artifactId>jdom</artifactId> + <version>1.1</version> + <type>jar</type> + <scope>compile</scope> + </dependency> + <dependency> + <groupId>log4j</groupId> + <artifactId>log4j</artifactId> + <version>1.2.14</version> + <type>jar</type> + <scope>compile</scope> + </dependency> + <dependency> + <groupId>com.itextpdf</groupId> + <artifactId>itextpdf</artifactId> + <version>5.0.4</version> + <scope>compile</scope> + </dependency> + <dependency> + <groupId>org.mortbay.jetty</groupId> + <artifactId>servlet-api</artifactId> + <version>3.0.20100224</version> + <type>jar</type> + <scope>provided</scope> + </dependency> + </dependencies> + </dependencyManagement> <properties> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> </properties> + <inceptionYear>2001</inceptionYear> + <developers> + <developer> + <id>robcast</id> + <name>Robert Casties</name> + <email>robcast@berlios.de</email> + <organization>Max Planck Institute for the History of Science</organization> + <organizationUrl>http://www.mpiwg-berlin.mpg.de</organizationUrl> + <roles> + </roles> + </developer> + <developer> + <id>hertzhaft</id> + <name>Martin Raspe</name> + <email>hertzhaft@berlios.de</email> + <organization>Bibliotheca Hertziana</organization> + <organizationUrl>http://www.biblhertz.it</organizationUrl> + </developer> + </developers> + <scm> + <url>http://hg.berlios.de/repos/digilib</url> + </scm> <dependencies> </dependencies> <modules>
--- a/servlet/pom.xml Wed Apr 20 15:25:59 2011 +0200 +++ b/servlet/pom.xml Wed Apr 20 21:40:38 2011 +0200 @@ -19,67 +19,51 @@ <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> </properties> - <repositories> - <repository> - <id>itextpdf.com</id> - <name>Maven Repository for iText</name> - <url>http://maven.itextpdf.com/</url> - </repository> - <!-- This provides the required versions of JAI-ImageIO --> - <repository> - <id>geotools.osgeo.org</id> - <name>Geotools repository</name> - <url>http://download.osgeo.org/webdav/geotools/</url> - </repository> - </repositories> - <dependencies> <dependency> <groupId>javax.media</groupId> <artifactId>jai_imageio</artifactId> - <version>1.1</version> + <type>jar</type> + <scope>compile</scope> </dependency> <dependency> <groupId>javax.media</groupId> <artifactId>jai_codec</artifactId> - <version>1.1.3</version> + <type>jar</type> + <scope>compile</scope> </dependency> <dependency> <groupId>javax.media</groupId> <artifactId>jai_core</artifactId> - <version>1.1.3</version> + <type>jar</type> + <scope>compile</scope> </dependency> <dependency> <groupId>org.devlib.schmidt</groupId> <artifactId>imageinfo</artifactId> - <version>1.9</version> <type>jar</type> <scope>compile</scope> </dependency> <dependency> <groupId>org.jdom</groupId> <artifactId>jdom</artifactId> - <version>1.1</version> <type>jar</type> <scope>compile</scope> </dependency> <dependency> <groupId>log4j</groupId> <artifactId>log4j</artifactId> - <version>1.2.14</version> <type>jar</type> <scope>compile</scope> </dependency> <dependency> <groupId>com.itextpdf</groupId> <artifactId>itextpdf</artifactId> - <version>5.0.4</version> <scope>compile</scope> </dependency> <dependency> <groupId>org.mortbay.jetty</groupId> <artifactId>servlet-api</artifactId> - <version>3.0.20100224</version> <type>jar</type> <scope>provided</scope> </dependency>