[Bedework-commit] r597 - in trunk/calendar3: bldfiles deployment docs webclient/war/WEB-INF webclient/war/docs

svnadmin at bedework.org svnadmin at bedework.org
Mon Jun 19 00:50:00 EDT 2006


Author: douglm
Date: 2006-06-19 00:49:30 -0400 (Mon, 19 Jun 2006)
New Revision: 597

Added:
   trunk/calendar3/bldfiles/quickstart-build.xml
   trunk/calendar3/docs/README
Modified:
   trunk/calendar3/bldfiles/buildwar.xml
   trunk/calendar3/bldfiles/defjars.properties
   trunk/calendar3/deployment/build.xml
   trunk/calendar3/webclient/war/WEB-INF/publicweb.xml
   trunk/calendar3/webclient/war/docs/footer.jsp
Log:
Further uportal changes:

This allows building of the public events client as a uportal jsr168 portlet.

Instructions to follow. Changes are:

Add file missed in previous change

Change deployment/build.xml to add property org.bedework.deploy.type.dir
defining directory for type of application being built.

Add uportal2 target to bldfiles/buildwar.xml - needs application property portal.platform

Change webclient/war/WEB-INF/publicweb.xml to add servlet class and genurl tokens.

Create deployment/webpublic/uportal2 and add portlet.xml struts-portlet-config.xml

Add commons-collections to war for hibernate - define in defjars

servlet-jsp.jar should not be included in deployment. Probably needs upgrading for build
Enable pagecontext flush in footer


Modified: trunk/calendar3/bldfiles/buildwar.xml
===================================================================
--- trunk/calendar3/bldfiles/buildwar.xml	2006-06-19 00:54:12 UTC (rev 596)
+++ trunk/calendar3/bldfiles/buildwar.xml	2006-06-19 04:49:30 UTC (rev 597)
@@ -12,10 +12,8 @@
 
      Properties which must be defined on entry, apart from those described
      in the main build file are:
-    app.root.dir       Location of the root directory for the apps -
-                       appsuite or uwcalapps probably
-    app.sou.dir        Location of the application skeleton, e.g.
-                       appsuite/admin
+    app.root.dir       Location of the root directory for the apps
+    app.sou.dir        Location of the application skeleton,
     app.name           Name of the application. This wil be used to determine
                        the name of the file containing the rest of the
                        application properties, the directory we build in
@@ -41,14 +39,18 @@
      Authors: Mike Douglass   douglm at rpi.edu
      =================================================================== -->
 
-<project name="uwcal.buildwar" default="build" >
-  <target name="init" depends="init.common,init.j2ee,init.standalone" />
+<project name="bedework.buildwar" default="build" >
+  <target name="init" depends="init.common,init.uportal2,init.j2ee,init.standalone" />
 
   <target name="init.common">
     <condition property="org.bedework.build.for.jetspeed2">
-      <equals arg1="jetspeed2" arg2="${propval.portal.platform}"/>
+      <equals arg1="jetspeed2" arg2="${propval.app.portal.platform}"/>
     </condition>
 
+    <condition property="org.bedework.build.for.uportal2">
+      <equals arg1="uportal2" arg2="${propval.app.portal.platform}"/>
+    </condition>
+
     <condition property="org.bedework.build.for.jboss">
       <equals arg1="jboss" arg2="${org.bedework.global.j2ee.platform}"/>
     </condition>
@@ -79,7 +81,29 @@
               location="${app.sou.dir}/war/WEB-INF/classes/servlet.properties" />
   </target>
 
+  <target name="init.uportal2" if="org.bedework.build.for.uportal2" >
+    <property name="propval.app.servlet.class"
+              value="org.apache.portals.bridges.struts.PortletServlet" />
+
+    <property name="propval.app.ignoreContentType"
+              value="true" />
+
+    <property name="propval.app.genurl.taglib.tld"
+              value="struts-portlet.tld" />
+  </target>
+
   <target name="init.standalone" if="org.bedework.global.build.standalone.app">
+    <property name="propval.app.servlet.class"
+              value="org.apache.struts.action.ActionServlet" />
+
+    <property name="propval.app.ignoreContentType"
+              value="false" />
+
+    <property name="propval.app.portlet.mapping" value="" />
+
+    <property name="propval.app.genurl.taglib.tld"
+              value="struts-html.tld" />
+
     <property name="app.dest.lib"
               location="${app.dest.webinf}/lib" />
   </target>
@@ -121,9 +145,18 @@
       <filter token="DIRECTORY-BROWSING-DISALLOWED"
               value="${org.bedework.global.directory.browsing.disallowed}" />
 
+      <filter token="IGNORE-CONTENT-TYPE"
+              value="${propval.app.ignoreContentType}" />
+
       <filter token="APP-DESCRIPTION"
               value="${propval.app.description}" />
 
+      <filter token="SERVLET-CLASS"
+              value="${propval.app.servlet.class}"/>
+
+      <filter token="GENURL-TAGLIB-TLD"
+              value="${propval.app.genurl.taglib.tld}"/>
+
       <filter token="SECURITY-DOMAIN"
               value="${propval.app.security.domain}"/>
       <filter token="SECURITY-PREFIX"
@@ -164,13 +197,13 @@
     </filterset>
 
     <available file="${app.sou.dir}/properties" type="dir"
-               property="uwcal.properties.dir.exists" />
+               property="org.bedework.properties.dir.exists" />
 
     <available file="${app.sou.properties}" type="file"
-               property="uwcal.servlet.properties.exists" />
+               property="org.bedework.servlet.properties.exists" />
 
     <available file="${app.sou.dir}/war/docs" type="dir"
-               property="uwcal.war.docs.exists" />
+               property="org.bedework.war.docs.exists" />
 
     <antcall target="copy.properties" inheritRefs="true" />
     <antcall target="copy.servlet.properties" inheritRefs="true" />
@@ -243,6 +276,7 @@
     <!-- Some more standard libs -->
     <copy todir="${app.dest.lib}" file="${log4j.jar}"/>
     <copy todir="${app.dest.lib}" file="${ical4j.jar}"/>
+    <copy todir="${app.dest.lib}" file="${commons-collections.jar}"/>
 
     <!-- add the jdbcdriver if defined -->
     <antcall target="add.jdbcdriver" inheritRefs="true" />
@@ -271,7 +305,7 @@
     <copy todir="${app.dest.lib}" file="${app.jdbcdriver.jar}"/>
   </target>
 
-  <target name="copy.properties" if="uwcal.properties.dir.exists">
+  <target name="copy.properties" if="org.bedework.properties.dir.exists">
     <!-- ===============================================================
          Any property files we need for configuration, other than the
          standard struts file, should be in the "${app.sou.dir}/properties
@@ -285,13 +319,13 @@
     </copy>
   </target>
 
-  <target name="copy.servlet.properties" if="uwcal.servlet.properties.exists">
+  <target name="copy.servlet.properties" if="org.bedework.servlet.properties.exists">
     <copy tofile="${app.dest.classes}/servlet.properties" file="${app.sou.properties}">
       <filterset refid="property.filters" />
     </copy>
   </target>
 
-  <target name="copy.war.docs" if="uwcal.war.docs.exists">
+  <target name="copy.war.docs" if="org.bedework.war.docs.exists">
     <copy todir="${app.dest.docs}">
       <fileset dir="${app.sou.dir}/war/docs" />
     </copy>
@@ -325,6 +359,7 @@
 
     <antcall target="add.xalan" inheritRefs="true" />
     <antcall target="add.jetspeed2" inheritRefs="true" />
+    <antcall target="add.uportal2" inheritRefs="true" />
 
     <copy todir="${app.dest.lib}">
       <fileset dir="${struts.dir}">
@@ -339,17 +374,15 @@
     <copy todir="${app.dest.lib}" file="${commons-logging.jar}"/>
     <copy todir="${app.dest.lib}" file="${commons-validator.jar}"/>
     <copy todir="${app.dest.lib}" file="${jakarta-oro.jar}"/>
-
-    <copy todir="${app.dest.lib}" file="${servlet.jsp.jar}"/>
   </target>
 
   <target name="add.jetspeed2" if="org.bedework.build.for.jetspeed2" >
     <copy todir="${app.dest.webinf}"
-          file="${org.bedework.portal.resources.dir}/jetspeed2/${propval.app.war.name}/portlet.xml"
+          file="${org.bedework.deploy.type.dir}/jetspeed2/${propval.app.war.name}/portlet.xml"
           overwrite="yes"
           failonerror="no" />
     <copy todir="${app.dest.webinf}"
-          file="${org.bedework.portal.resources.dir}/jetspeed2/struts-portlet-config.xml"
+          file="${org.bedework.deploy.type.dir}/jetspeed2/struts-portlet-config.xml"
           overwrite="yes"
           failonerror="no" />
 
@@ -365,16 +398,55 @@
       </fileset>
     </copy>
 
-    <!-- Overwrite the web.xml file -->
-    <copy tofile="${app.dest.web.xml}"
-          file="${org.bedework.portal.resources.dir}/jetspeed2/web.xml"
-          overwrite="yes" >
-      <filterset>
-        <filter token="RPI-DEBUG" value="${app.debug.val}"/>
-      </filterset>
-      <filterset refid="property.filters" />
+    <!-- Add the portal bridge controller def -->
+    <replace file="${app.dest.webinf}/struts-config.xml">
+      <replacetoken><![CDATA[<!-- Jetspeed2 controller def here -->]]></replacetoken>
+      <replacevalue><![CDATA[<controller pagePattern="$M$P" inputForward="true"
+              processorClass="org.apache.portals.bridges.struts.PortletRequestProcessor"/>]]>
+      </replacevalue>
+    </replace>
+  </target>
+
+  <target name="add.uportal2" if="org.bedework.build.for.uportal2" >
+    <copy todir="${app.dest.webinf}"
+          file="${org.bedework.deploy.type.dir}/uportal2/portlet.xml"
+          overwrite="yes"
+          failonerror="no" />
+    <copy todir="${app.dest.webinf}"
+          file="${org.bedework.deploy.type.dir}/uportal2/struts-portlet-config.xml"
+          overwrite="yes"
+          failonerror="no" />
+
+    <copy todir="${app.dest.lib}" >
+      <fileset dir="${portals-bridges.jars.dir}">
+        <include name="*.jar"/>
+      </fileset>
     </copy>
 
+    <copy todir="${app.dest.webinf}/tlds"
+          overwrite="yes"
+          failonerror="no" >
+      <fileset dir="${org.bedework.deploy.type.dir}/uportal2" >
+        <include name="*.tld"/>
+      </fileset>
+    </copy>
+
+    <copy todir="${app.dest.lib}" file="${org.bedework.uportal.jar}" />
+
+    <!-- Add the portlet servelt mapping -->
+    <replace file="${app.dest.webinf}/web.xml">
+      <replacetoken><![CDATA[<!-- uPortal2 portlet servlet mapping here -->]]></replacetoken>
+      <replacevalue><![CDATA[<servlet-mapping>
+    <servlet-name>@PORTLET-NAME@</servlet-name>
+    <url-pattern>/@PORTLET-NAME@/*</url-pattern>
+  </servlet-mapping>]]>
+      </replacevalue>
+    </replace>
+
+    <replace file="${app.dest.webinf}/web.xml">
+      <replacefilter token="@PORTLET-NAME@" value="${propval.app.portlet.name}"/>
+    </replace>
+
     <!-- Add the portal bridge controller def -->
     <replace file="${app.dest.webinf}/struts-config.xml">
       <replacetoken><![CDATA[<!-- Jetspeed2 controller def here -->]]></replacetoken>

Modified: trunk/calendar3/bldfiles/defjars.properties
===================================================================
--- trunk/calendar3/bldfiles/defjars.properties	2006-06-19 00:54:12 UTC (rev 596)
+++ trunk/calendar3/bldfiles/defjars.properties	2006-06-19 04:49:30 UTC (rev 597)
@@ -67,6 +67,9 @@
 #      commons-codec.jar    Used for encode/decode.
 commons-codec.jar=${commons.dir}/commons-codec-1.3.jar
 
+#      commons-collections.jar    Used by hibernate.
+commons-collections.jar=${commons.dir}/commons-collections.jar
+
 #      commons-fileupload.jar    Used for struts
 commons-fileupload.jar=${commons.dir}/commons-fileupload.jar
 

Added: trunk/calendar3/bldfiles/quickstart-build.xml
===================================================================
--- trunk/calendar3/bldfiles/quickstart-build.xml	                        (rev 0)
+++ trunk/calendar3/bldfiles/quickstart-build.xml	2006-06-19 04:49:30 UTC (rev 597)
@@ -0,0 +1,580 @@
+<?xml version="1.0"?>
+
+<!-- This is the ant build file for the bedework Calendar quickstart.
+
+     It is imported by the quickstart build.xml ensuring all changes to this file
+     appear in the repository.
+
+     Authors: Mike Douglass   douglm at rpi.edu
+-->
+
+<project name="quickstart-build-file" default="usage" basedir=".">
+  <property environment="env"/>
+
+  <target name="README" depends="init"
+          description="Describe targets and their usage">
+    <loadfile property="org.bedework.README" srcFile="${calendar.dir}/docs/README"/>
+    <echo message="${org.bedework.README}" />
+  </target>
+
+  <target name="usage" depends="init"
+          description="Describe targets and their usage">
+    <echo message="As distributed the package should be ready to go."/>
+    <echo message="Ensure ant is on your path, (a version is in the" />
+    <echo message="package)"/>
+    <echo message=""/>
+    <echo message="First in one window do"/>
+    <echo message="    ant hsqldb"/>
+    <echo message="This will start the hsqldb server ready for the "/>
+    <echo message="application."/>
+    <echo message=""/>
+    <echo message="In another window do"/>
+    <echo message="    ant tomcatstart"/>
+    <echo message=""/>
+    <echo message="Once tomcat is running you should be able to go to a"/>
+    <echo message="browser and connect to"/>
+    <echo message="    http://localhost:8080/caladmin"/>
+    <echo message="and get a login prompt. Login with user 'caladmin' and"/>
+    <echo message="password 'uwcal'"/>
+    <echo message=""/>
+    <echo message="Connecting to"/>
+    <echo message="    http://localhost:8080/cal"/>
+    <echo message="should give you the public (guest) view of the calendar"/>
+    <echo message="which probably has no events."/>
+    <echo message=""/>
+    <echo message="Try entering them with the admin calendar ('add events')"/>
+    <echo message="and they should appear."/>
+    <echo message=""/>
+    <echo message="To build the calendar do"/>
+    <echo message="    ant deploy    or "/>
+    <echo message="    ant deploy.debug "/>
+    <echo message="which does a build and deploy of all components"/>
+    <echo message=""/>
+    <echo message="To rebuild the calendar do"/>
+    <echo message="    ant clean.deploy    or "/>
+    <echo message="    ant clean.deploy.debug "/>
+    <echo message="which does a clean, build and deploy of all components"/>
+    <echo message=""/>
+    <echo message="Creating a locally configured calendar application"/>
+    <echo message="should involve following the instructions for the"/>
+    <echo message="appsuite target in calendar/build.xml"/>
+    <echo message=""/>
+  </target>
+
+   <!-- The only properties set below should be those directly used to
+        invoke the targets below, in this file.
+        Do not set properties here for tasks invoked in other build
+        files.  Instead, make sure the targets work in calendar/build.xml,
+        then invoke ant on the task in calendar/build.xml.
+
+        For an example, of invoking ant on another build file,
+        see the deploy target, below.
+     -->
+  <target name="init" >
+    <dirname property="quickstart.dir" file="${ant.file}"/>
+
+    <property name="calendar.dir"
+              location="${basedir}/calendar3" />
+
+    <property name="calendar.build.file"
+              location="${calendar.dir}/build.xml" />
+
+    <!-- Overriding this when invoking ant allows different user property
+         files to be included e.g.
+            ant -Dorg.bedework.user.build.properties=/home/me/bedework.properties ...
+            -->
+    <property name="org.bedework.user.build.properties"
+              location="${user.home}/bedework.build.properties" />
+
+    <echo message="Load user properties from ${org.bedework.user.build.properties}" />
+
+    <!-- Load user property definition overrides -->
+    <property file="${org.bedework.user.build.properties}" />
+
+    <!-- Then standard build properties -->
+    <property file="${calendar.dir}/build.properties"/>
+
+    <property name="org.bedework.hsqldb.dir"
+              location="${basedir}/hsqldb-1.7.3.3" />
+    <property name="org.bedework.hsqldb.dbname"
+              value="demo/events" />
+    <property name="org.bedework.hsqldb.test.dbdir"
+              value="test" />
+
+    <property name="org.bedework.appserver.dir"
+              location="${basedir}/jakarta-tomcat-5.0.28" />
+    <property name="sync4j.dir"
+              location="${basedir}/Sync4j2.2b3" />
+
+    <property name="org.bedework.appserver.deploy.dir"
+              location="${org.bedework.appserver.dir}/webapps" />
+  </target>
+
+  <!-- =================================================================
+       The "build" target builds the jar files
+       ================================================================= -->
+
+  <target name="build" depends="init"
+          description="builds the jars">
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="bld.all" />
+  </target>
+
+  <target name="clean.build" depends="clean"
+          description="cleans then builds the jars">
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="bld.all" />
+  </target>
+
+  <!-- =================================================================
+       The "deploy" target builds and deploys the applications
+       ================================================================= -->
+
+  <target name="deploy" depends="init"
+          description="builds and deploys the applications">
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="deploy" />
+  </target>
+
+  <target name="deploy.debug" depends="init"
+          description="builds and deploys the applications">
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="deploy.debug" />
+  </target>
+
+  <!-- =================================================================
+       The "clean.deploy" target cleans, builds and deploys the applications
+       ================================================================= -->
+
+  <target name="clean.deploy" depends="clean,deploy" />
+
+  <target name="clean.deploy.debug" depends="clean,deploy.debug" />
+
+  <target name="clean" depends="init"
+          description="Remove all generated files.">
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="clean" />
+  </target>
+
+  <!-- =================================================================
+       The "build.configured" target builds configured applications
+       ================================================================= -->
+
+  <target name="build.configured" depends="init"
+          description="Build configured applications" >
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="build.configured" />
+  </target>
+
+  <target name="build.configured.debug" depends="init"
+          description="Build configured applications" >
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="build.configured.debug" />
+  </target>
+
+  <target name="clean.build.configured" depends="clean"
+          description="Build configured applications" >
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="build.configured" />
+  </target>
+
+  <target name="clean.build.configured.debug" depends="clean"
+          description="Build configured applications" >
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="build.configured.debug" />
+  </target>
+
+  <!-- =================================================================
+       dump and restore targets
+       ================================================================= -->
+
+  <target name="dumpdb" depends="build,dumpdb.nobuild"
+          description="run dump "/>
+
+  <target name="dumpdb.nobuild" depends="init"
+          description="run dump without a rebuild">
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="dumpdb" />
+  </target>
+
+  <target name="restoredb" depends="build,restoredb.nobuild"
+          description="run restore "/>
+
+  <target name="restoredb-nousers" depends="build"
+          description="run restore but strip out most user stuff. Useful for demo data">
+    <input message="Restoring will destroy this calendar db. Proceed with restore"
+           validargs="y,n"
+           addproperty="do.restore" />
+    <condition property="do.abort">
+      <equals arg1="n" arg2="${do.restore}"/>
+    </condition>
+    <fail if="do.abort">restore aborted by user.</fail>
+
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+         target="restoredb-nousers" />
+  </target>
+
+  <target name="restoredb.nobuild" depends="init"
+          description="run restore without a rebuild">
+    <input message="Restoring will destroy this calendar db. Proceed with restore"
+           validargs="y,n"
+           addproperty="do.restore" />
+    <condition property="do.abort">
+      <equals arg1="n" arg2="${do.restore}"/>
+    </condition>
+    <fail if="do.abort">restore aborted by user.</fail>
+
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+         target="restoredb" />
+  </target>
+
+  <target name="initdb" depends="build,initdb.nobuild"
+          description="run restore to initialise db"/>
+
+  <target name="initdb.nobuild" depends="init"
+          description="run restore to initialise db">
+    <input message="Restoring will destroy this calendar db. Proceed with restore"
+           validargs="y,n"
+           addproperty="do.restore" />
+    <condition property="do.abort">
+      <equals arg1="n" arg2="${do.restore}"/>
+    </condition>
+    <fail if="do.abort">restore aborted by user.</fail>
+
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+         target="initdb" />
+  </target>
+
+  <target name="tzconvert" depends="build"
+          description="Convert timezones for use in bedework">
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+         target="tzconvert" />
+  </target>
+
+  <target name="bld.config" depends="init"
+          description="Build config and deploy module">
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="bld.config" />
+  </target>
+
+  <!-- =================================================================
+       Build and run the unit test suite
+       ================================================================= -->
+
+  <target name="bld.test" depends="init"
+          description="Build and run tests">
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+         target="bld.test" />
+  </target>
+
+  <target name="run.test" depends="init"
+          description="Build and run tests">
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+         target="run.test" />
+  </target>
+
+  <target name="run.test.debug" depends="init"
+          description="Build and run tests">
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+         target="run.test"  >
+      <property name="org.bedework.debug" value="yes" />
+    </ant>
+  </target>
+
+  <!-- Rebuild the http test suite only -->
+  <target name="httptest" depends="init"
+          description="Run httptest suite" >
+    <input message="httptest may destroy this calendar db. Proceed with test"
+           validargs="y,n"
+           addproperty="do.httptest" />
+    <condition property="do.abort">
+      <equals arg1="n" arg2="${do.httptest}"/>
+    </condition>
+    <fail if="do.abort">httptest aborted by user.</fail>
+
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="bld.httptest" />
+
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="run.httptest" />
+  </target>
+
+  <!-- =================================================================
+       Run the synchml test application
+       ================================================================= -->
+
+  <target name="synchmltest" depends="init"
+          description="Run the synchml test application" >
+    <input message="synchmltest may destroy this calendar db. Proceed with test"
+           validargs="y,n"
+           addproperty="do.synchmltest" />
+    <condition property="do.abort">
+      <equals arg1="n" arg2="${do.synchmltest}"/>
+    </condition>
+    <fail if="do.abort">synchmltest aborted by user.</fail>
+
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="synchmltest" />
+  </target>
+
+  <!-- ======================== schema target =======================
+       This builds the ddl from the hibernate schema
+       ================================================================= -->
+
+  <target name="schema" depends="init"
+          description="Generate schema from mapping files">
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="schema" />
+  </target>
+
+  <!-- ======================== javadoc target =======================
+       ================================================================= -->
+
+  <target name="javadoc" depends="init"
+          description="Generate javadoc">
+    <ant antfile="${calendar.build.file}" inheritrefs="true"
+           target="javadoc" />
+  </target>
+
+  <!-- =================================================================
+       The "hsqldb" target starts the hsqldb server
+       ================================================================= -->
+
+  <target name="hsqldb" depends="init"
+          description="starts the hsqldb server">
+    <echo message="Starting hsqldb"/>
+    <java fork="true" dir="${basedir}" classname="org.hsqldb.Server">
+      <classpath>
+        <pathelement path="${org.bedework.hsqldb.dir}/lib/hsqldb.jar"/>
+      </classpath>
+      <arg value="-database"/>
+      <arg value="${org.bedework.hsqldb.dir}/${org.bedework.hsqldb.dbname}"/>
+      <arg value="-port"/>
+      <arg value="8887"/>
+    </java>
+  </target>
+
+  <target name="hsqldb-trace" depends="init"
+          description="starts the hsqldb server">
+    <echo message="Starting hsqldb"/>
+    <java fork="true" dir="${basedir}" classname="org.hsqldb.Server">
+      <classpath>
+        <pathelement path="${org.bedework.hsqldb.dir}/lib/hsqldb.jar"/>
+      </classpath>
+      <arg value="-trace"/>
+      <arg value="true"/>
+      <arg value="-silent"/>
+      <arg value="false"/>
+      <arg value="-database"/>
+      <arg value="${org.bedework.hsqldb.dir}/${org.bedework.hsqldb.dbname}"/>
+      <arg value="-port"/>
+      <arg value="8887"/>
+    </java>
+  </target>
+
+  <target name="uportaldb" depends="init"
+          description="starts the hsqldb server">
+    <echo message="Starting hsqldb"/>
+    <java fork="true" dir="${basedir}" classname="org.hsqldb.Server">
+      <classpath>
+        <pathelement path="${org.bedework.hsqldb.dir}/lib/hsqldb.jar"/>
+      </classpath>
+      <arg value="-database"/>
+      <arg value="${org.bedework.hsqldb.dir}/uportal"/>
+      <arg value="-port"/>
+      <arg value="9887"/>
+    </java>
+  </target>
+
+  <!-- =================================================================
+       The "hsqldb-test" target starts the hsqldb server for testing
+       ================================================================= -->
+
+  <target name="hsqldb-test" depends="init"
+          description="starts the hsqldb server for testing">
+    <echo message="Starting hsqldb for testing"/>
+    <delete dir="${org.bedework.hsqldb.dbdir}" />
+
+    <java fork="true" dir="${basedir}" classname="org.hsqldb.Server">
+      <classpath>
+        <pathelement path="${org.bedework.hsqldb.dir}/lib/hsqldb.jar"/>
+      </classpath>
+      <arg value="-database"/>
+      <arg value="${org.bedework.hsqldb.dir}/${org.bedework.hsqldb.test.dbdir}/events"/>
+      <arg value="-port"/>
+      <arg value="8887"/>
+    </java>
+  </target>
+
+  <target name="hsqldb-test-trace" depends="init"
+          description="starts the hsqldb server for testing">
+    <echo message="Starting hsqldb for testing"/>
+    <delete dir="${org.bedework.hsqldb.dbdir}" />
+
+    <java fork="true" dir="${basedir}" classname="org.hsqldb.Server">
+      <classpath>
+        <pathelement path="${org.bedework.hsqldb.dir}/lib/hsqldb.jar"/>
+      </classpath>
+      <arg value="-trace"/>
+      <arg value="true"/>
+      <arg value="-silent"/>
+      <arg value="false"/>
+      <arg value="-database"/>
+      <arg value="${org.bedework.hsqldb.dir}/${org.bedework.hsqldb.test.dbdir}/events"/>
+      <arg value="-port"/>
+      <arg value="8887"/>
+    </java>
+  </target>
+
+  <!-- =================================================================
+       The "hsqldb-mngr" target runs the DatabaseManager class which
+       provides a gui interface to the running hsqldb database.
+       ================================================================= -->
+
+  <target name="hsqldb-mngr" depends="init"
+          description="Runs the DatabaseManager class which provides a
+                       gui interface to the running hsqldb database">
+    <echo message="Starting hsqldb DatabaseManager"/>
+    <echo message="Select type: HSQL Database Engine Server"/>
+    <echo message="Set the URL to jdbc:hsqldb:hsql://localhost:8887"/>
+    <java fork="true" dir="${basedir}"
+          classname="org.hsqldb.util.DatabaseManager">
+      <classpath>
+        <pathelement path="${org.bedework.hsqldb.dir}/lib/hsqldb.jar"/>
+      </classpath>
+    </java>
+  </target>
+
+  <!-- =================================================================
+       The "tomcatstart" target starts Tomcat
+       ================================================================= -->
+
+  <target name="tomcatstart-locale" depends="init"
+          description="starts the tomcat server">
+    <input message="Enter language code: "
+           addproperty="tomcat.locale" />
+
+    <input message="Enter country code: "
+           addproperty="tomcat.country" />
+
+    <echo message="Starting Tomcat from ${org.bedework.appserver.dir}"/>
+    <java fork="true" dir="${basedir}"
+          classname="org.apache.catalina.startup.Bootstrap">
+      <classpath>
+        <pathelement path="${org.bedework.appserver.dir}/bin/bootstrap.jar"/>
+      </classpath>
+      <sysproperty key="catalina.home" value="${org.bedework.appserver.dir}"/>
+      <!--jvmarg value="-Dcatalina.home=${tomcat.dir}"/-->
+      <jvmarg value="-Duser.language=${tomcat.locale}"/>
+      <jvmarg value="-Duser.country=${tomcat.country}"/>
+      <!--
+      <jvmarg value="-Dfile.encoding=ISO-8859-1"/>
+      -->
+      <arg value="start"/>
+    </java>
+  </target>
+
+  <target name="tomcatstart" depends="init"
+          description="starts the tomcat server">
+    <echo message="Starting Tomcat from ${org.bedework.appserver.dir}"/>
+    <java fork="true" dir="${basedir}"
+          classname="org.apache.catalina.startup.Bootstrap">
+      <classpath>
+        <pathelement path="${org.bedework.appserver.dir}/bin/bootstrap.jar"/>
+      </classpath>
+      <sysproperty key="catalina.home" value="${org.bedework.appserver.dir}"/>
+      <!--jvmarg value="-Dcatalina.home=${tomcat.dir}"/-->
+      <jvmarg value="-Djava.net.preferIPv4Stack=true"/>
+      <arg value="start"/>
+    </java>
+  </target>
+
+  <target name="tomcatstart-profile" depends="init"
+          description="starts the tomcat server with rpofiling">
+    <echo message="Starting Tomcat from ${org.bedework.appserver.dir}"/>
+    <java fork="true" dir="${basedir}"
+          classname="org.apache.catalina.startup.Bootstrap">
+      <classpath>
+        <pathelement path="${org.bedework.appserver.dir}/bin/bootstrap.jar"/>
+      </classpath>
+      <sysproperty key="catalina.home" value="${org.bedework.appserver.dir}"/>
+      <!--jvmarg value="-Dcatalina.home=${tomcat.dir}"/-->
+      <jvmarg value="-Xrunyjpagent:cpu=times,onexit=cpu" />
+      <jvmarg value="-Djava.net.preferIPv4Stack=true"/>
+      <arg value="start"/>
+    </java>
+  </target>
+
+  <target name="tomcatstart-profile-large" depends="init"
+          description="starts the tomcat server with rpofiling">
+    <echo message="Starting Tomcat from ${org.bedework.appserver.dir}"/>
+    <java fork="true" dir="${basedir}"
+          classname="org.apache.catalina.startup.Bootstrap">
+      <classpath>
+        <pathelement path="${org.bedework.appserver.dir}/bin/bootstrap.jar"/>
+      </classpath>
+      <sysproperty key="catalina.home" value="${org.bedework.appserver.dir}"/>
+      <!--jvmarg value="-Dcatalina.home=${tomcat.dir}"/-->
+      <jvmarg value="-Xms128m" />
+      <jvmarg value="-Xmx630m" />
+      <!--
+      <jvmarg value="-XX:PermSize=128m" />
+      <jvmarg value="-XX:MaxPermSize=128m" />
+      -->
+      <jvmarg value="-server" />
+      <jvmarg value="-Xrunyjpagent:cpu=times,onexit=cpu" />
+      <jvmarg value="-Djava.net.preferIPv4Stack=true"/>
+      <arg value="start"/>
+    </java>
+  </target>
+
+  <target name="tomcatstart-debug" depends="init"
+          description="starts the tomcat server with remote debugging enabled">
+    <echo message="Starting Tomcat from ${org.bedework.appserver.dir}"/>
+    <java fork="true" dir="${basedir}"
+          classname="org.apache.catalina.startup.Bootstrap">
+      <classpath>
+        <pathelement path="${org.bedework.appserver.dir}/bin/bootstrap.jar"/>
+      </classpath>
+      <sysproperty key="catalina.home" value="${org.bedework.appserver.dir}"/>
+      <!--jvmarg value="-Dcatalina.home=${tomcat.dir}"/-->
+      <jvmarg value="-Djava.net.preferIPv4Stack=true"/>
+      <jvmarg value="-Xdebug"/>
+      <jvmarg value="-Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=n"/>
+      <arg value="start"/>
+    </java>
+  </target>
+
+  <!-- This target is for use when sync4j is installed -->
+  <target name="tomcatstart-sync4j" depends="init"
+          description="starts the tomcat server with sync4j">
+    <echo message="Starting Tomcat 5.0.16 with sync4j"/>
+    <java fork="true" dir="${basedir}"
+          classname="org.apache.catalina.startup.Bootstrap">
+      <classpath>
+        <pathelement path="${org.bedework.appserver.dir}/bin/bootstrap.jar"/>
+      </classpath>
+      <sysproperty key="catalina.home" value="${org.bedework.appserver.dir}"/>
+      <!--jvmarg value="-Dcatalina.home=${tomcat.dir}"/-->
+      <jvmarg value="-Dsync4j.home=${sync4j.dir}"/>
+      <arg value="start"/>
+    </java>
+  </target>
+
+  <!-- =================================================================
+       The "tomcatstop" target stops Tomcat cleanly
+       ================================================================= -->
+
+  <target name="tomcatstop" depends="init">
+    <echo message="Stopping Tomcat 5.0.16"/>
+    <java fork="true" dir="${basedir}"
+          classname="org.apache.catalina.startup.Bootstrap">
+      <classpath>
+        <pathelement path="${org.bedework.appserver.dir}/bin/bootstrap.jar"/>
+      </classpath>
+      <sysproperty key="catalina.home" value="${org.bedework.appserver.dir}"/>
+      <!--jvmarg value="-Dcatalina.home=${tomcat.dir}"/-->
+      <arg value="stop"/>
+    </java>
+  </target>
+</project>

Modified: trunk/calendar3/deployment/build.xml
===================================================================
--- trunk/calendar3/deployment/build.xml	2006-06-19 00:54:12 UTC (rev 596)
+++ trunk/calendar3/deployment/build.xml	2006-06-19 04:49:30 UTC (rev 597)
@@ -227,7 +227,10 @@
     </forEachApp>
 
     <!-- ======================= termination tasks ================= -->
-    <ant antfile="${org.bedework.deployment.base}/termination/${org.bedework.deploy.kind}/build.xml"
+    <property name="org.bedework.deploy.type.dir"
+              location="${org.bedework.deployment.base}/termination" />
+
+    <ant antfile="${org.bedework.deploy.type.dir}/${org.bedework.deploy.kind}/build.xml"
          inheritrefs="true" target="build.configured" />
   </target>
 
@@ -239,7 +242,10 @@
       <globmapper from="org.bedework.app.${org.bedework.deploy.name}.*" to="propval.app.*"/>
     </propertyset>
 
-    <ant antfile="${org.bedework.deployment.base}/${org.bedework.deploy.type}/${org.bedework.deploy.kind}/build.xml"
+    <property name="org.bedework.deploy.type.dir"
+              location="${org.bedework.deployment.base}/termination" />
+
+    <ant antfile="${org.bedework.deploy.type.dir}/${org.bedework.deploy.kind}/build.xml"
          inheritrefs="true" target="build.configured" >
       <propertyset refid="app-properties" />
     </ant>
@@ -255,14 +261,21 @@
     </forEachApp>
 
     <!-- ======================= termination tasks ================= -->
-    <ant antfile="${org.bedework.deployment.base}/termination/${org.bedework.deploy.kind}/build.xml"
+    <property name="org.bedework.deploy.type.dir"
+              location="${org.bedework.deployment.base}/termination" />
+
+    <ant antfile="${org.bedework.deploy.type.dir}/${org.bedework.deploy.kind}/build.xml"
          inheritrefs="true" target="deploy" />
   </target>
 
   <target name="wrap.deploy.available.app">
     <!-- just to make app.kind.available go away -->
-    <available file="${org.bedework.deployment.base}/${org.bedework.deploy.type}/${org.bedework.deploy.kind}/build.xml"
+    <property name="org.bedework.deploy.type.dir"
+              location="${org.bedework.deployment.base}/${org.bedework.deploy.type}" />
+
+    <available file="${org.bedework.deploy.type.dir}/${org.bedework.deploy.kind}/build.xml"
                property="app.kind.available" />
+
     <antcall target="deploy.available.app" inheritrefs="true" />
   </target>
 
@@ -272,7 +285,10 @@
       <globmapper from="org.bedework.app.${org.bedework.deploy.name}.*" to="propval.app.*"/>
     </propertyset>
 
-    <ant antfile="${org.bedework.deployment.base}/${org.bedework.deploy.type}/${org.bedework.deploy.kind}/build.xml"
+    <property name="org.bedework.deploy.type.dir"
+              location="${org.bedework.deployment.base}/${org.bedework.deploy.type}" />
+
+    <ant antfile="${org.bedework.deploy.type.dir}/${org.bedework.deploy.kind}/build.xml"
          inheritrefs="true" target="deploy" >
       <propertyset refid="app-properties" />
     </ant>

Added: trunk/calendar3/docs/README
===================================================================
--- trunk/calendar3/docs/README	                        (rev 0)
+++ trunk/calendar3/docs/README	2006-06-19 04:49:30 UTC (rev 597)
@@ -0,0 +1,41 @@
+Bedework Calendar System
+------------------------
+
+Most documenation is available at bedework.org
+
+This quickstart release allows those who want a packaged working demonstration
+system to easily see the bedework calendar system in operation.
+
+System requirements
+-------------------
+JDK 1.4 or higher
+JAVA_HOME environment variable must be set
+Nothing else should be running on port 8080 and 8887.
+
+Instructions.
+------------
+First ensure for linux that the file named "ant" in the quickstart directory is
+marked executable. In the following instructions <ANT> is
+On Windows:    ant.bat
+Linux          ./ant
+
+From within the quickstart directory and in separate windows type the following:
+
+window 1:
+<ANT> hsqldb
+
+window 2:
+<ANT> tomcatstart
+
+Now go to
+http://localhost:8080/bedework/
+
+Which will give you the choice of a number of applications. For those which
+require a login valid userids and passwords are in
+
+<tomcat-dir>/conf/tomcat-users.xml.
+
+Currently, the demonstration administrative client requires a login with the id
+
+douglm  password bedework
+

Modified: trunk/calendar3/webclient/war/WEB-INF/publicweb.xml
===================================================================
--- trunk/calendar3/webclient/war/WEB-INF/publicweb.xml	2006-06-19 00:54:12 UTC (rev 596)
+++ trunk/calendar3/webclient/war/WEB-INF/publicweb.xml	2006-06-19 04:49:30 UTC (rev 597)
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="ISO-8859-1"?>
 
-<!-- guest/web.xml and user/web.xml in uwcalxml should be
+<!-- publicweb.xml and userweb.xml should be
      identical except for the security piece.
   -->
 
@@ -9,7 +9,7 @@
          xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
          http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
          version="2.4">
-  <display-name>UWCal public client</display-name>
+  <display-name>Bedwork public client</display-name>
 
   <context-param>
     <param-name>rpiappname</param-name>
@@ -37,6 +37,10 @@
       <param-name>directoryBrowsingDisallowed</param-name>
       <param-value>@DIRECTORY-BROWSING-DISALLOWED@</param-value>
     </init-param>
+    <init-param>
+      <param-name>ignoreContentType</param-name>
+      <param-value>@IGNORE-CONTENT-TYPE@</param-value>
+    </init-param>
   </filter>
 
   <filter>
@@ -102,12 +106,27 @@
   <servlet>
     <servlet-name>action</servlet-name>
     <servlet-class>
-      org.apache.struts.action.ActionServlet
+      @SERVLET-CLASS@
     </servlet-class>
 
     <load-on-startup>1</load-on-startup>
   </servlet>
 
+  <!-- Servlet definition for portlet use. uportal only at the moment -->
+  <servlet>
+    <servlet-name>@PORTLET-NAME@</servlet-name>
+    <display-name>@PORTLET-NAME@ Wrapper</display-name>
+    <servlet-class>org.apache.pluto.core.PortletServlet</servlet-class>
+    <init-param>
+      <param-name>portlet-class</param-name>
+      <param-value>org.apache.portals.bridges.struts.StrutsPortlet</param-value>
+    </init-param>
+    <init-param>
+      <param-name>portlet-guid</param-name>
+      <param-value>@CONTEXT-ROOT at .@PORTLET-NAME@</param-value>
+    </init-param>
+  </servlet>
+
   <servlet-mapping>
     <servlet-name>action</servlet-name>
     <url-pattern>*.rdo</url-pattern>
@@ -118,6 +137,8 @@
     <url-pattern>*.do</url-pattern>
   </servlet-mapping>
 
+  <!-- uPortal2 portlet servlet mapping here -->
+
   <session-config>
     <session-timeout>30</session-timeout>
   </session-config>
@@ -142,11 +163,12 @@
       <taglib-uri>struts-html</taglib-uri>
       <taglib-location>/WEB-INF/tlds/struts-html.tld</taglib-location>
     </taglib>
-    <!-- use html struts tag library for genurl -->
+
     <taglib>
       <taglib-uri>struts-genurl</taglib-uri>
-      <taglib-location>/WEB-INF/tlds/struts-html.tld</taglib-location>
+      <taglib-location>/WEB-INF/tlds/@GENURL-TAGLIB-TLD@</taglib-location>
     </taglib>
+
     <taglib>
       <taglib-uri>struts-logic</taglib-uri>
       <taglib-location>/WEB-INF/tlds/struts-logic.tld</taglib-location>
@@ -160,6 +182,12 @@
       <taglib-uri>bedework</taglib-uri>
       <taglib-location>/WEB-INF/tlds/bedework.tld</taglib-location>
     </taglib>
+
+    <!-- Only used for portlet -->
+    <taglib>
+        <taglib-uri>http://java.sun.com/portlet</taglib-uri>
+        <taglib-location>/WEB-INF/tlds/pluto-portlet.tld</taglib-location>
+    </taglib>
   </jsp-config>
 
   <!-- JDBC DataSources (java:comp/env/jdbc) -->

Modified: trunk/calendar3/webclient/war/docs/footer.jsp
===================================================================
--- trunk/calendar3/webclient/war/docs/footer.jsp	2006-06-19 00:54:12 UTC (rev 596)
+++ trunk/calendar3/webclient/war/docs/footer.jsp	2006-06-19 04:49:30 UTC (rev 597)
@@ -79,7 +79,6 @@
 }
 %>
 
-<%-- Required to force write in jetspeed2 portal-struts bridge
-< % pageContext.getOut().flush(); % >
---%>
+<%-- Required to force write in portal-struts bridge --%>
+<% pageContext.getOut().flush(); %>
 



More information about the Bedework-commit mailing list