Integrating Address Book Server into an existing Tomcat instance
To configure an existing Tomcat installation to run Address Book Server it is best to start with the generic Linux distribution. After extracting the ZIP archive transfer the following files from the extracted folder structure to your existing Tomcat installation.
Transfer files
- apache-tomcat-6.0.24/bin/setenv.bat
- apache-tomcat-6.0.24/bin/setenv.sh
- apache-tomcat-6.0.24/webapps/AddressBookServer.war
- apache-tomcat-6.0.24/lib/AddressBookServerTomcat.jar
- apache-tomcat-6.0.24/lib/META-INF (including content)
- apache-tomcat-6.0.24/lib/ehcache.xml
- apache-tomcat-6.0.24/lib/h2-latest.jar
- apache-tomcat-6.0.24/lib/log4j.jar
- apache-tomcat-6.0.24/lib/log4j.xml
Edit Configuration files
Configure the conf/server.xml file to suite your requirements. Typically this requires the addition of a Context element as shown below.
<Context path="" docBase="AddressBookServer.war">
<Environment name="LicenseFile" value="LicenseKey.license" type="java.lang.String" override="true"/>
<Environment name="BackupsFolder" value="../backups" type="java.lang.String" override="true"/>
<Resource name="jdbc/AddressBookDB" auth="Container" type="javax.sql.DataSource"
maxActive="25" maxIdle="5" maxWait="-1"
username="sa" password="" driverClassName="org.h2.Driver"
url="jdbc:h2:tcp://localhost:48081/../db/AddressBookDB;LOCK_TIMEOUT=60000"/>
<Realm className="org.apache.catalina.realm.JDBCRealm"
driverName="org.h2.Driver"
connectionURL="jdbc:h2:tcp://localhost:48081/../db/AddressBookDB;LOCK_TIMEOUT=60000"
connectionName="sa" connectionPassword=""
userTable="WEBUSERS" userNameCol="USERID" userCredCol="PASSWORD"
userRoleTable="WEBROLES" roleNameCol="ACCESSROLE"/>
</Context>
The following page describes how to run multiple instances of Address Book Server on the same Tomcat instance. This information also applies running Address Book Server in an existing instance.
Create the following new folders
- apache-tomcat-6.0.24/db
- apache-tomcat-6.0.24/ssl
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)