Installation within Tomcat
This document describes how to install Membrane Registry into the Tomcat Servlet container.
Tomcat
To install Tomcat download the binary distribution as zip file(eg. 6.0.18) from Apache. Unzip it in any directory.
Setting up a Datasource
Hibernate Dialect
The registry uses the Hibernate object relational mapping tool. Usually Hibernate will adjust to itself to the right database dialect. In some cases however you have to specify the hibernate database dialect. Either by specifing a Java property:
Simply include the following line at the beginning of catalina.bat:
set JAVA_OPTS= -Dhibernate.dialect=[HibernateDialect]
You can use any SQL database that has a JDBC driver for the Membrane Registry. In this document the Apache Derby database is used. But you can adapt the configuration to your JDBC compliant database as well.
Derby database
Open context.xml located at the conf subdirectory of your Tomcat installation directory. Add a Resource element as a child to the context element:
<Resource name="jdbc/membrane" type="javax.sql.DataSource" auth="Container" description="Derby database for membrane registry" maxActive="100" maxIdle="30" maxWait="10000" username="App" password="" factory="org.apache.tomcat.dbcp.dbcp.BasicDataSourceFactory" driverClassName="org.apache.derby.jdbc.EmbeddedDriver" url="jdbc:derby:c:/membrane-registry/membranedb;create=true"/>
Hint: Encoded into the JDBC url is the location of the Derby database.
Copy the derby.jar from the lib subdirectory of the distribution to the lib directory of tomcat.
Other databases
If you are using a different database set the driverClassName attribute of the Resource element to the appropriate JDBC driver and copy the driver JAR of your database to the lib directory of tomcat.
Deploing the Membrane WebApp
Copy the registry.war file from the Membrane Registry distribution to the webapps directory of your Tomcat installation(e.g C:\apache-tomcat-6.0.18\webapps) and start Tomcat.
Test the service
Take a look at the registry with your browser using the url http://localhost:8080/registry. Maybe you have to ajust the port number.

Figure 1:
Now you can start registring Web Services.
Troubleshooting
In some cases the JVM can run out of memory. If you encounter this open catalina.bat in your Tomcat bin directory and include the following line at the beginning:
set JAVA_OPTS= -Xms512m -Xmx512m -XX:MaxPermSize=256m
Copyright (c) 2009 predic8 GmbH.
