IndiaWebDevelopers.comA global technology company specializing in web applications and enterprise solutionsContact UsAbout UsFAQHome
India Web Developers - A global technology company specializing in web applications and enterprise solutions  
YOU ARE HERE: TECHNOLOGY > CONFIGURING SLIDE WITH CATALINA
 
Technology
Design Tools
Open Source
Java-Centric Technologies
Oracle 9i
Microsoft-Centric Technologies
ASP.NET
Cutting-Edge Technologies
Search Engine Technologies
XML
ZOPE
Related Links
Other Links
SEARCH
 

Configuring Slide with Catalina

By Karan Dass

   

Configuring Slide with Catalina

What are Slide and Catalina?

Slide is a project composed of multiple modules tied together using WebDAV. It includes:

1) A content management system with a Java API
2) A servlet implementing the WebDAV protocol on top of the content management system
3) A Java WebDAV and HTTP client library
4) A WebDAV command line client
5) WebDAV enabled Swing components

The Slide project main module is a Content Management and Integration System, which can be seen as a low-level content management framework. Conceptually, it provides a hierarchical organization of binary content which can be stored into arbitrary, heterogeneous, distributed data stores. In addition, Slide integrates security, locking, versioning, as well as many other services.

Catalina is a new servlet container, which is implemented by Tomcat 4.0.

Configuring Slide

First of all download Slide and Tomcat. Slide can be downloaded from here and Tomcat 4.0.2 from here.

Step 1:

Get Tomcat to authenticate users. To add the users to Tomcat, go to %CATALINA_HOME%\conf and edit the file tomcat-users.xml so that it includes logins for the default slide users:

< tomcat-users >
<user name="tomcat" password="tomcat" roles="tomcat" />
<user name="role1" password="tomcat" roles="role1" />
<user name="both" password="tomcat" roles="tomcat,role1" />
<user name="guest" password="guest" roles="tomcat,guest" />
<user name="root" password="root" roles="tomcat,root" />
</ tomcat-users >

Step 2:

Copy the slide.war and slidedoc.war from Slide directory into %CATALINA_HOME%\webapps

Step 3:

Start tomcat (%CATALINA_HOME%\bin\startup.bat). This should unpack the war files so that you now have a directory %CATALINA_HOME%\webapps\slide and one for %CATALINA_HOME%\webapps\slidedoc.

Shutdown tomcat (%CATALINA_HOME%\bin\shutdown.bat)

Step 4:

Edit %CATALINA_HOME%\webapps\slide\WEB-INF\web.xml. Look for the line <!-- security-constraint > and remove the "!--", thus turning the line into an XML tag as opposed to a comment. Similarly remove the "--" from the 3rd last line in the file (</ login-config -->).

Step 5:

Restart tomcat.

Step 6:

If all goes well, you should see (in your tomcat console) the output from slide as it loads the "Domain" etc. It should look something like this:

Starting service Tomcat-Standalone

Apache Tomcat/4.0-b3
30 Apr 2001 13:03:56 - INFO - Initializing Domain
30 Apr 2001 13:03:56 - INFO - Domain configuration : {org.apache.slide.security=true}
30 Apr 2001 13:03:56 - INFO - Initializing namespace : webdav
30 Apr 2001 13:03:56 - INFO - Loading namespace definition
30 Apr 2001 13:03:56 - INFO - Registering Store memory of class class org.apache.slide.store.StandardStore with parameters {} on scope /
30 Apr 2001 13:03:57 - INFO - Initializing Store memory(org.apache.slide.store.StandardStore)
30 Apr 2001 13:03:57 - INFO - Loading namespace webdav parameters
30 Apr 2001 13:03:57 - INFO - Loading namespace webdav base data
WARNING: No active transaction
30 Apr 2001 13:03:58 - INFO - Namespace base configuration was already done before
30 Apr 2001 13:03:58 - INFO - Loading namespace webdav configuration
30 Apr 2001 13:03:58 - INFO - Namespace configuration complete
Starting service Tomcat-Apache
Apache Tomcat/4.0-2

Step 7:

To change where slide stores information, you will need to modify the Domain configuration file: %CATALINA_HOME%\webapps\slide\Domain.xml. In it, you'll see a commented out store that uses the hSQL database driver. You can uncomment that and install hSQL if you prefer. The following steps assume you want to run slide with the "MySQL" database.

Step 8:

In the Domain.xml file, replace the < definition >...</ definition > section with the following (note, you may want to set user and password to your own values. Also, this assumes that the MySQL server is the same machine as that which runs slide - if not, change "localhost" to point to your MySQL server):

< definition >
< store name="memory" >
< nodestore classname="slidestore.reference.JDBCDescriptorsStore" >
< parameter name="driver" >org.gjt.mm.mysql.Driver</ parameter >
< parameter name="url" >
mysql://localhost:3306/myDB?user=MYslideuser&amp;password=MYslidepass</parameter >
< parameter name="jdbcversion" >1</ parameter >
</ nodestore >
< securitystore >
< reference store="nodestore" />
</ securitystore >
< lockstore >
< reference store="nodestore" />
</ lockstore >
< revisiondescriptorsstore >
< reference store="nodestore" />
</ revisiondescriptorsstore >
< revisiondescriptorstore >
< reference store="nodestore" />
</ revisiondescriptorstore >
< contentstore classname="slidestore.reference.JDBCContentStore" >
< parameter name="driver" >org.gjt.mm.mysql.Driver</ parameter >
< parameter name="url" >
mysql://localhost:3306/myDB?user=MYslideuser&amp;password=MYslidepass</ parameter>
< parameter name="jdbcversion" >1</ parameter >
</ contentstore >
<!-- contentstore classname="slidestore.reference.FileContentStore" >
< parameter name="rootpath" >files</ parameter >
</ contentstore -->
</ store >
< scope match="/" store="memory" />
</ definition >

Step 9:

Obtain the MySQL driver from here and and unpack it, copying the resulting ".jar" file into %CATALINA_HOME%\webapps\slide\WEB-INF\lib\

For this setup to work, you need to be running the MySQL version 3.23 or later. Version 3.22 and earlier did not support transactions.

Create a MySQL user/password to match the ones you set up in Step 8. This account will need write access to the "myDB" database.

Copy the script for setting up the MySQL schema from this link by cutting and pasting it into a mysql session.

Stop and restart Tomcat, logging in as root/root. Now, when you create files and objects, they should be stored in the "objects" and "revisioncontent" tables of your database.

Inquire here for your custom software development requirements

Related Links - Java Centric

 
 
 
 
Contact us with your project needs for a Quick Reply!
 
     
 


Web Development India
The web division of Stylus Systems Pvt Ltd www.stylusinc.com ©1999-2008