With Apache JServ
#1. Specify the path to the necessary packages
Place the packages that you will not be changing into the wrapper.classpath
(in jserv.properties). Please see this FAQ entry (line wrapped) for more
information on determining what will change and what won't change look
here.
Here is an example:
 |
 |
 |
 |
wrapper.classpath=<path to>/ECS.jar
wrapper.classpath=<path to>/Village.jar
wrapper.classpath=<path to>/jndi.jar
wrapper.classpath=<path to>/mail.jar
wrapper.classpath=<path to>/activation.jar
|
 |
 |
 |
 |
Place the rest of the classes that you will be using, such as your Turbine
classes into the repositories path that is defined in your zone.properties
file.
#2. Run the appropriate SQL script for your database. If a script for your
specific database is not present, the SQL can easily be adapted. We
appreciate your contributions here. If your database is not supported by
the connection pooling code, please subscribe to the mailing list and ask
for help there. Include the type of database and the driver information in
your posting.
 |
 |
 |
 |
mysqladmin create turbine
mysql turbine < tables.schema
|
 |
 |
 |
 |
Please note that the tables.schema file is not actually a single file. The
various schema files exist in the src/sql/ directory. You will need to choose the
appropriate .sql file for your needs according to what database you are using.
We currently have .sql files for Oracle, MySQL, DB2, Hypersonic,
Sybase, InstantDB, and Postgres. The ones that are
the most tested and reliable are the MySQL files because this is our database of
choice. Contributions for more databases is most appreciated.
#3. Edit TurbineResources.properties file (in the conf directory), define
your database types and make sure that the database adaptor for your
database is uncommented, and place this file in a directory accessible to
your servlet engine.
#4. Specify an initial parameter named "properties" (without the quotes)
with the pathname to the TurbineResources.properties file as its value.
This can be accomplished by placing the following line in your
[zone].properties file:
 |
 |
 |
 |
servlet.Turbine.initArgs=properties=/path/to/TurbineResources.properties
|
 |
 |
 |
 |
With Tomcat
Note that the TDK includes Catalina, which is Tomcat 4.0. All the
necessary JAR files for Turbine are included in the target
application when you use the TDK, and this is the recommended method
of using Tomcat. If you need to deploy a TDK application to another
Tomcat installation, you should be able to make a WAR file of the
application and drop it into the webapps directory on the target
platform.
The following instructions assume that you have followed the above
instructions for either source compilation or release distribution. This
also assumes that you have working Tomcat installation which can be
found here.
-
TOMCAT_HOME=/path/to/tomcat
-
Put all necessary Turbine-related jars (Turbine, ECS, Village,
JNDI) into $TOMCAT_HOME/lib.
-
Add the path to the jars to the existing Tomcat CLASSPATH found in
$TOMCAT_HOME/bin/tomcat.sh
-
Make necessary adjustments to TurbineResources.properties and copy into
$TOMCAT_HOME/webapps/YOUR_APP_CONTEXT/WEB-INF/conf
-
Add the following xml to $TOMCAT_HOME/$TOMCAT_HOME/webapps/YOUR_APP_CONTEXT/WEB-INF/web.xml. It
will be a child of the web-app element.
 |
 |
 |
 |
<servlet>
<servlet-name>Turbine</servlet-name>
<servlet-class>org.apache.turbine.Turbine</servlet-class>
<init-param>
<param-name>properties</param-name>
<param-value>WEB-INF/conf/TurbineResources.properties</param-value>
</init-param>
</servlet>
|
 |
 |
 |
 |