Building XEP servlet
Posted by gregster on 04 Feb 2010 in R & D, Activity log
For the new machine we want to deploy a standalone XEP engine rather than embedding it in to any given app.
I downloaded the latest version from RenderX (4.17-20091204) and found a connector called servlet. To build this on 64bit Linux I had to install the JDK (Sun), Tomcat, and junit (making sure to set JAVA_HOME in my .bashrc file:
export JAVA_HOME=/usr/lib/jvm/java-6-sun
export PATH=$PATH:/usr/lib/jvm/java-6-sun/bin ).
I then edited the build.props file (in the devkit/connectors/Servlet/ directory) to look like this:
xep.dir=/home/gregster/Applications/XEP
servlet.interface.jar=/home/gregster/Applications/Tomcat/lib/servlet-api.jar
junit.jar=/usr/share/java/junit4-4.6.jar
and ran ant (as in typing the word "ant" and hitting the "Enter" key)
This successfully built a war file in the build directory.
To make things explicit:
1) xep.dir - to have a xep.dir to point to, you need to install xep itself, running the setup.jar file downloaded from RenderX). You then point xep.dir at the topmost directory of the install tree.
2) servlet.interface.jar - this points to the servlet jar file that comes with Tomcat. In the case of Tomcat 6, the file is actually called servlet-api.jar but it'll always be in Tomcat's lib directory. If you miss this you'll get javax errors.
3) junit.jar - install junit (in the repos) or you'll get problems. Apparently, the junit that ships with ant is insufficient.