Running ACS Java under Resin

by Bill Schneider
Configuring ACS Java to work with Resin 1.2.x, a commercial servlet/JSP engine, is easy to do. Follow these directions if you're interested in trying:
  1. download Resin from www.caucho.com and install it. Call this directory $RESIN_HOME
  2. download or cvs checkout acs-java-4 and put it somewhere. Call this directory $ACS_JAVA.
  3. edit your inet/port settings in $RESIN_HOME/conf/resin.conf, and add the following line in the host section:
    <web-app id='/' app-dir="/path/to/acs-java-4"/>
    
    This will map the root URL to ACS Java.
  4. change the <jsp> section to disable static encoding:
    <jsp precompile='true' static-encoding='false'/>
    

    Static encoding is an optimization that speeds up JSP output by converting static HTML text in JSPs to static byte arrays, so that charset conversion (two-byte chars to one-byte ints) only has to happen once per string per JVM, rather than every time out.print(something) is called for each page invocation. So

    out.println("this is a string literal");
    
    becomes something like:
    static byte[] _jsp_string_0 = "this is a string literal".getBytes();
    out.write(_jsp_string_0);
    
    But this optimization is implemented in a way that breaks explicit pageContext.pushBody()calls from JSP, which we need to make the templating <property> tag work.
  5. Run Resin's httpd.sh in the environment set up by the "run" shell script:
    $ACS_JAVA/run $RESIN_HOME/bin/httpd.sh
    

Revision History

Document Revision # Action Taken, Notes When? By Whom?
0.1 Creation January 20, 2001 Bill Schneider

acs-docs@arsdigita.com
Last modified: resin.html,v 1.1 2001/01/21 01:50:42 bquinn Exp