husted      01/02/19 12:39:27

  Modified:    src/doc  installation.xml
  Added:       src/doc  installation-wls.xml installation-jrun.xml
                        installation-sas.xml installation-tc.xml
                        installation-ubs.xml installation-was.xml
  Log:
  (Submitted by Ted Husted). Per Craig's suggestions: * Make the page names include 
just the server name, and not
    the version number.  That way, you can have separate sections
    on the page for each individual version of the same server.  New
    sections can be conveniently added to the bottom as new versions
    of the servers come out.  Maybe include a hyperlink index at the
    top of each page for all the documented version numbers?
  
  * On the Tomcat page, I've seen so many problems with bugs in
    Tomcat 3.1 that I do not recommend it as a platform for Struts
    based apps.  I'd like to have the install documents recommend
    that people upgrade to at least Tomcat 3.2.1.
  
  * The Tomcat instructions related to integration with Apache apply
    only to 3.1 and 3.2 -- the instructions for 4.0 will be different.
  Right
    now, the 4.0 section should just talk about running stand alone,
    though -- the 4.0 web connector is not ready for prime time.
  
  Revision  Changes    Path
  1.15      +8 -7      jakarta-struts/src/doc/installation.xml
  
  Index: installation.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-struts/src/doc/installation.xml,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -r1.14 -r1.15
  --- installation.xml  2001/02/19 19:52:51     1.14
  +++ installation.xml  2001/02/19 20:39:25     1.15
  @@ -230,19 +230,20 @@
   <h3>Status of various containers</h3>
   
   <ul>
  -  <li>Tomcat 3.1+ "standalone" - No additonal steps required.</li>
  +  <li>Tomcat 3.1 and prior - Not recommended. Use Tomcat 3.2.1 or later.</li>
  +  <li>Tomcat 3.2.1+ "standalone" - No additional steps required.</li>
     <li>Resin 2.1+ "standalone" - No additional steps required.</li>
     <li>WebLogic 6.0+ - No additional steps required.</li>
   </ul>
   
   <ul>
  -  <li>Bluestone Universal Business Server - <a 
href="installation-ubs72.html">Additional steps required.</a></li>
  -  <li>JRUN - <a href="installation-jr30.html">Additional steps required.</a></li>
  +  <li>Bluestone Universal Business Server - <a 
href="installation-ubs.html">Additional steps required.</a></li>
  +  <li>JRUN - <a href="installation-jrun.html">Additional steps required.</a></li>
     <li>Orion Application Server - <a href="installation-oas.html">Additional steps 
required.</a></li>
  -  <li>Silverstream - - <a href="installation-sas371.html">Additional steps 
required.</a></li>
  -  <li>Tomcat 3.1+ with Apache - <a href="installation-tc31.html">Additional steps 
required.</a></li>
  -  <li>Weblogic 5.1 (sp8) - <a href="installation-wls5.html">Additional steps 
required.</a></li>
  -  <li>WebSphere  - <a href="installation-was352.html">Additional steps 
required.</a></li>
  +  <li>Silverstream - - <a href="installation-sas.html">Additional steps 
required.</a></li>
  +  <li>Tomcat 3.2.1 with Apache - <a href="installation-tc.html">Additional steps 
required.</a></li>
  +  <li>Weblogic 5.1 (sp8) - <a href="installation-wls.html">Additional steps 
required.</a></li>
  +  <li>WebSphere - <a href="installation-was.html">Additional steps 
required.</a></li>
   </ul>
   
   
  
  
  
  1.1                  jakarta-struts/src/doc/installation-wls.xml
  
  Index: installation-wls.xml
  ===================================================================
  <?xml version="1.0"?>
  <document url="./installation-wls.xml">
  
    <properties>
      <author>Robert Hayden</author>
      <author>Wong Kok Kai</author>
      <title>The Struts Framework Project - Installation - Weblogic</title>
    </properties>
  
    <body>
  
  <section name="Installing Struts with your servlet container" href="Containers"> 
  
  <h3><a name="wls5">Weblogic 5.1 (service pack 8)</a></h3>
  <ul>
    <li>Obtain and install the Xerces XML parser (problems have been reported with 
      the Sun reference implementation). Put xerces.jar in your WebLogic system 
      path.</li>
    <li>Obtain and unpack the Struts binary distribution (this procedure assumes 
      it was extracted to <code>c:\jakarta-struts</code>).</li>
    <li>Add an entry to weblogic.properties for each of the Struts web applications 
      that you would like to configure. For example, to make the struts-example 
      application available, add the following line to weblogic.properties:<br/>
      <code>weblogic.httpd.webApp.strutsexample=<br/>
      c:/jakarta-struts/webapps/struts-example.war</code></li>
    <li>You do not need to include struts.jar or any of the application specific 
      classes in the WebLogic classpath, since this will be done automatically (unless 
      deploying an unpacked web archive- see below).</li>
    <li>Start WebLogic server and point your web browser to the struts application. 
      For example, to connect to the example application added in step 3:<br/>
      <code>http://localhost:7001/strutsexample</code></li>
    <li>This example application depends on the Struts specific resource file 
ApplicationResources.properties 
      to be present on the classpath. However, WebLogic only extracts *.class files 
      from the archive so this file will not be found, resulting in an error the 
      first time it is needed- something similar to: javax.servlet.ServletException: 
      runtime failure in custom tag 'message'. Steps 6 &amp; 7 will need to be 
performed 
      for this application, and any other that relies on 
ApplicationResources.properties.</li>
    <li>Extract ApplicationResources.properties from the *.war file, and manually 
      copy it to the respective package in the _tmp_war_ directory WebLogic created 
      for this application. Again referring to the struts-example application, this 
      would be:<br/>
      <code>c:\jakarta-struts\webapps\WEB-INF\_tmp_war_strutsexample</code></li>
    <li>Restart WebLogic. You will now be able to run the application:<br/>
      <code>http://localhost:7001/strutsexample</code></li>
  </ul>
  <p>The above steps should be followed for applications deployed as *.war files. 
    For unpacked web applications, configuration involves adding both 
<code>struts.jar</code> 
    and <code>/WEB-INF/classes</code> to the WebLogic classpath. For this reason, 
    I would suggest deploying applications as war files to WebLogic. However, the 
    same example application can be successfully deployed in extracted format by 
    modifying weblogic.properties (assuming the war was extracted to directory 
webapps/struts-example):</p>
  <p><code>weblogic.httpd.webApp.strutsexample=<br/>
    c:/jakarta-struts/webapps/struts-example/</code></p>
  <p>And starting WebLogic with the updated WebLogic classpath. For example:</p>
  <p><code>c:\jdk1.3\bin\java -ms16m -mx64m<br/>
    -classpath c:\weblogic\lib\weblogic510sp8boot.jar;</code></p>
    <hr/>
    <h4>Additional Recommendations</h4>
    <ul>
    <li>Servlet and JSP-Reloading should be turned off. First, you pay a performance 
      penalty. Depending on the number of JSPs, the number of requests and the 
        configured checking interval, the server will slow down. Second, with JSP- and 
        Servlet reloading, one opens the door for various Weblogic classloader 
problems, 
        that are difficult to diagnose, difficult to handle and often lead to lost 
        HTTP-sessions.</li>
    <li>Set the name of the <code>sessionid</code> to <code>JSESSIONID</code>, if 
cookies are used for session 
      tracking and to jsessionid, if sessions are URL-based. (There are additional 
        problems related to URL-based sessions, caused from BEA's way to encode the 
session 
        id (J2EE-incompatible) as query-param. Especially &lt;bean:include&gt; will 
not work with 
        URL-based sessions yet. However, using the correct session name solves at 
least some 
        problems.)</li>
    <li>Configure the JSP-Servlet registration in <code>weblogic.properties</code> for 
      maximum J2EE-compliance and/or for maximum performance.</li></ul>
    <p>The JSP-Servlet supports some initialization parameters that can be customized 
to get 
      best performance, maximum compliance or (as shown below) easier debugging:</p>
  <pre>
    weblogic.httpd.initArgs.*.jsp=\
         pageCheckSeconds=-1,\
          setEmptyStrings=false,\
           compileCommand=./_jspCompiler_.cmd,\
               workingDir=/weblogic/myserver/tmp_classfiles,\
            keepgenerated=true,\
                    debug=true,\
                  verbose=true
  </pre>
  <p>In the above example, the batch file (<code>_jspCompiler_.cmd</code>) invokes 
jikes 
     which results dramatically reduced startup times (jikes is about three times 
faster 
     than javac.) The batchfile contains only a single line:</p>
  
  <pre>@jikes -g -nowarn %*</pre>
  
  <p>The next configuration could be used when all tests have been done and speed is 
the 
  major concern ...</p>
  
  <pre>  
    weblogic.httpd.initArgs.*.jsp=\
         pageCheckSeconds=-1,\
          setEmptyStrings=false,\
           compileCommand=./_jspCompiler_.cmd,\
               workingDir=/weblogic/myserver/tmp_classfiles,\
            keepgenerated=false,\
                    debug=false,\
                  verbose=false
  </pre>
  
  <p>... together with ...</p>
  
  <pre>@jikes -O -nowarn %*</pre>
  
  <p>Weblogic supports similar settings through <code>&lt;context-params&gt;</code> in 
<code>web.xml</code>
  (Please read the latest documentation at the BEA website for details.)</p>
  <p>For additional issues, see also <a 
  href="http://www.mail-archive.com/struts-dev@jakarta.apache.org/msg00284.html">More 
  fixes for WLS 5.1 SP8</a> from the Struts Developer mailing list</p>
  <hr/>  
    <ul>
      <li>Author: Robert Hayden</li>
      <li>Author: Wong Kok Kai</li>
      <li>Author: Matthias Kerkhoff </li>
    </ul>
    <hr/>  
    <p>Back to <a href="installation.html#Containers">Installation</a></p>
  </section>
  </body>
  </document>
  
  
  
  1.1                  jakarta-struts/src/doc/installation-jrun.xml
  
  Index: installation-jrun.xml
  ===================================================================
  <?xml version="1.0"?>
  <document url="./installation-jrun.xml">
  
    <properties>
      <author>Eric Wu</author>
      <title>The Struts Framework Project - Installation - JRun</title>
    </properties>
  
    <body>
  
  <section name="Installing Struts with your servlet container" href="Containers"> 
  
  <h3><a name="jr30">JRUN 3.0 SP2A, VERSION 3.02A.11614</a></h3>
  
  <b>Tested with: Microsoft IIS 5.0, Windows 2000</b>
  
  <h4>Important Note:</h4>
  
  <p>At the moment, JRun is not fully compliant with the JSP 1.1/1.2
  specification. </p>
  
  <p>Specifically, the automatic type conversions for custom tag parameters 
  specified in "Issue  7" of the JSP 1.1 Errata and in the JSP 1.2 Proposed 
  Final Draft have not yet been implemented.</p>
  
  <p>As it stands, JSP pages that make use of Struts taglibs whose parameters
  require  conversion (such as booleans) will not compile under JRun. This 
  includes the Struts Example Application. Attempting to run the example 
  application will result in an exception similar to the following being 
  thrown:</p>
  
  <pre>
  /struts-example/index.jsp:
  
  javax.servlet.ServletException: Compilation error occured: 
  
  allaire.jrun.scripting.DefaultCFE: 
  
  Errors reported by compiler:
  c:/JRun/servers/default/Struts 
    Example/WEB-INF/jsp/jrun__index2ejspa.java:41:1:41:27: 
  
  Error: No match was found for method "setLocale(java.lang.String)".
  </pre>
  
  <p>(For more details see refer to:<br/>
  <font size="-1"><a 
href="http://www.mail-archive.com/struts-user@jakarta.apache.org/msg01860.html">http://www.mail-archive.com/struts-user@jakarta.apache.org/msg01860.html</a></font>)</p>
  
  <p>The following instructions describe how to install the Struts Example
  Application under JRun. A subsequent section describes how the Struts Example 
  Application can be patched to work with Struts</p>
  
  <p>The following instructions assume the following:</p>
  
  <ul>
  <li>JRun has been installed and integrated with the web server of choice.</li>
  
  <li>$APP_SERVER_NAME is the name of the application server used to host the 
    application.  (When JRun is first installed, it creates an application 
    server called JRun Default Server).</li>
  
  <li>$APP_SERVER_DIR is the directory used to hold applications hosted by 
    $APP_SERVER_NAME.  For the JRun Default Server, the directory is 
    $JRUN_HOME/servers/default where $JRUN_HOME is the directory where 
    JRun is installed.</li>
  </ul>
  
  <h4>Installing the struts example application</h4>
  
  <ul>
  <li>Login to the JRun Management Console.</li>
  
  <li>On the left pane, select $APP_SERVER_NAME. A page showing the
    current server status will be shown on the right pane.</li>
  
  <li>On the right pane, click on the WAR Deployment link. A page
    containing a list of the currently deployed web applications will be 
    shown.</li>
  
  <li>On the right pane, click on Deploy an Application. Complete the Web 
    Application Information form as follows:</li>
    
    <ul>
    <li>Servlet War File or Directory:  Enter the full path where
        struts-example.war is found or click on Browse to select 
        the path.</li>
    <li>JRun Server Name:  $APP_SERVER_NAME</li>
    <li>Application Name:  Struts Example</li>
    <li>Application Hosts:  All Hosts</li>
    <li>Application URL:   /struts-example</li>
    <li>Application Deploy Directory:  will default to 
        $APP_SERVER_NAME/Struts Example (or the name as specified for 
        Application Name).</li>
    </ul>
  
  <li>Once the form is complete, click on the Deploy button.</li>
  
  <li>If deployment is successful, restart the application server by
    clicking on <code>$APP_SERVER_NAME</code> on the left pane. A page showing the 
    current server status will be shown on the right pane. Click the 
    Restart Server button to restart the application server.</li>
  
  <li>Test the sample application by using the following URL in the
    browser:<br/>
      <code>http://hostname/struts-example/index.jsp</code><br/>
    The struts-documentation.war can be installed using the same 
    procedure.</li>
  </ul>
  
  <h4>Installing unpacked web applications</h4>
  
  <p>The above steps should be followed for applications deployed as 
<code>*.war</code> files.</p>
  
  <p>For unpacked web applications, configuration involves the following steps:</p>
  
  <ul>
  <li>From the JRun Management Console, select <code>$APP_SERVER_NAME</code> (on the
    left pane) and click on WAR Deployment (on the right pane).</li>
  
  <li>On the right pane, click on Create an Application and complete the
    Web Application Information form as follows:</li>
  
  <li>JRun Server Name:  $APP_SERVER_NAME</li>
  
    <ul>
    <li>Application Name:  myApplication</li>
    <li>Application Hosts:  All Hosts</li>
    <li>Application URL:   /myApplication</li>
    <li>Application Deploy Directory:  will default to<br/>
      <code>$APP_SERVER_NAME/myApplication</code></li>
    </ul>
  
  <li>Click on Create to submit the form.</li>
  
  <li>Once the web application is created, install and configure the struts
    components (struts.jar, struts*.tld, etc) for the web application under 
    <code>$APP_SERVER_NAME/myApplication/WEB-INF</code></li>
    
  <li>Install the remaining components of the application:  .class files,
    JSP pages,.properties files etc  as required.</li>
  
  <li>To configure the extension mapping of the request URI (ie *.do) to
    the action servlet, expand <code>$APP_SERVER_NAME</code> on the left pane, expand 
    the Web Applications branch and click on myApplication. The right pane 
    will display the configuration options for myApplication. Click on 
    Servlet URL Mappings. A list of existing mappings will be shown. Click 
    the Edit button and create the following entry:</li>
    
    <ul>
    <li>Virtual Path/Extension:   *.do</li>
    <li>Servlet Invoked:  action</li>
    </ul>
  
  <li>Click on the Update button to save the changes.</li>
  <li>Restart the application server.</li>
  <li>The application should now be accessible from the browser.</li>
  </ul>
  
  <p>The JRun application server will need to be restarted each time one of the
  following changes are made to the web application:</p>
  
  <ul>
  <li><code>.class</code> or <code>.jar</code> files are modified</li>
  <li><code>.properties</code> files are modified</li>
  <li><code>.xml</code> files are modified</li>
  </ul>
  
  <h4>Patching the struts example application</h4>
  
  <p>As mentioned at the beginning of these notes, the Struts Example Application
  will not run under JRun without modification.  The following changes will need 
  to be made:</p>
  
  <ul>
  <li>index.jsp, logon.jsp: Change &lt;html:html locale="true"> to <br/>&lt;html:html 
locale=&lt;%= true %>></li>
  <li>registration.jsp, subscription.jsp: Change all instances of filter="true" to 
<br/>filter=&lt;%= true %></li>
  </ul> 
    <hr/>
    <ul><li>Author: Eric Wu</li></ul>
    <hr/>
    <p>Back to <a href="installation.html#Containers">Installation</a></p>
  </section>
  </body>
  </document>
  
  
  
  1.1                  jakarta-struts/src/doc/installation-sas.xml
  
  Index: installation-sas.xml
  ===================================================================
  <?xml version="1.0"?>
  <document url="./installation-sas.xml">
  
    <properties>
     <author>John Rousseau</author>
      <title>The Struts Framework Project - Installation - Silverstream Application 
Server</title>
    </properties>
  
    <body>
  
  <section name="Installing Struts with your servlet container" href="Containers"> 
  
  <h3><a name="sas371">SilverStream Application Server 3.7.1</a></h3>
  
  <ul>
    <li>Start the SilverStream application server.</li>
    <li>Create an XML deployment plan for the 
&quot;<code>struts-example.war</code>&quot; 
        application. Call the file 
&quot;<code>struts-example-depl-plan.xml</code>&quot;. 
        You can use the following contents for the file</li>
  </ul>
  
  <hr/>
  
  <p>----- cut here -----</p>
  
  <pre>
  &lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
  &lt;!DOCTYPE warJarOptions PUBLIC
    &quot;-//SilverStream Software, Inc.//DTD J2EE WAR Deployment Plan//EN&quot;
    &quot;deploy_war.dtd&quot;&gt;
  &lt;warJarOptions&gt;
  &lt;warJar&gt;
  &lt;warJarName&gt;struts-example.war&lt;/warJarName&gt;
  &lt;isEnabled&gt;true&lt;/isEnabled&gt;
  &lt;urls&gt;&lt;el&gt;struts-example&lt;/el&gt;&lt;/urls&gt;
  &lt;/warJar&gt;
  &lt;/warJarOptions&gt;
  </pre>
  
  <p>----- cut here -----</p>
  
  <hr/>
  
  <p>Create an XML deployment plan for the 
&quot;<code>struts-documentation.war</code>&quot; 
      application. Call the file &quot;struts-documentation-depl-plan.xml&quot;. 
      You can use the following contents for the file:</p>
  
  <hr/>
  <p>----- cut here -----</p>
  
  <pre>
  &lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;
  &lt;!DOCTYPE warJarOptions PUBLIC
    &quot;-//SilverStream Software, Inc.//DTD J2EE WAR Deployment Plan//EN&quot;
    &quot;deploy_war.dtd&quot;&gt;
  &lt;warJarOptions&gt;
  &lt;warJar&gt;
  &lt;warJarName&gt;struts-example.war&lt;/warJarName&gt;
  &lt;isEnabled&gt;true&lt;/isEnabled&gt;
  &lt;urls&gt;&lt;el&gt;struts-documentation&lt;/el&gt;&lt;/urls&gt;
  &lt;/warJar&gt;
  &lt;/warJarOptions&gt;
  </pre>
  
  <p>----- cut here -----</p>
  <hr/>
  
  <p>Run the following &quot;<code>SilverCmd DeployWAR</code>&quot; commands to 
     deploy the applications. You can change 'localhost' to whatever server you
     are deploying to. You can change 'Silvermaster' to whatever
     database you are deploying to.</p>
     <ul>
       <li>SilverCmd DeployWar localhost Silvermaster struts-example.war -f 
struts-example-depl-plan.xml</li>
       <li>SilverCmd DeployWar localhost Silvermaster struts-documentation.war -f 
struts-documentation-depl-plan.xml</li>
     </ul>
    <hr/>
    <ul><li>Author: John Rousseau</li></ul>
    <hr/>
    <p>Back to <a href="installation.html#Containers">Installation</a></p>
  </section>
  </body>
  </document>
  
  
  
  1.1                  jakarta-struts/src/doc/installation-tc.xml
  
  Index: installation-tc.xml
  ===================================================================
  <?xml version="1.0"?>
  <document url="./installation-tc.xml">
  
    <properties>
      <author>Craig R. McClanahan</author>
      <title>The Struts Framework Project - Installation - Tomcat with Apache</title>
    </properties>
  
    <body>
  
  <section name="Installing Struts with your servlet container" href="Containers"> 
  <h3><a name="tc321">Tomcat 3.2.1 With Apache</a></h3>
  <p>Note that the instructions for Tomcat 4 will be different than those for Tomcat 
3, 
  but the Tomcat 4.0 web connector is still under development. Versions of Tomcat 
prior 
  to 3.2.1 are not recommend for use with Struts.</p>
  <ul>
    <li>These instructions assume you have successfully integrated Tomcat with Apache 
      according to the Tomcat documentation.</li>
    <li>Copy "struts-documentation.war" and "struts-example.war" to your 
$TOMCAT_HOME/webapps 
      directory</li>
    <li>Restart Tomcat if it is already running</li>
    <li>Tomcat will generate a file "$TOMCAT_HOME/conf/tomcat-apache.conf" that 
      will be used by Apache. This file is regenerated every time you start Tomcat, 
      so copy this file to a safe place (such as your Apache configuration directory; 
      on Unix systems this is usually <code>/usr/local/apache/conf</code>.</li>
    <li>If you are running Tomcat 3.1, Tomcat will not have generated the entries 
      for your new applications. Add the following lines to the 
<code>tomcat-apache.conf</code> 
      file that you have saved, replacing $TOMCAT_HOME with the path to your Tomcat 
      home directory:</li>
  </ul>
  <pre>
  Alias /struts-documentation "$TOMCAT_HOME/webapps/struts-documentation
    &lt;Directory "$TOMCAT_HOME/webapps/struts-documentation>
      Options Indexes FollowSymLinks
    &lt;/Directory>
      ApJServMount /struts-documentation/servlet /struts-documentation
    &lt;Location "/struts-documentation/WEB-INF/">
      AllowOverride None
      deny from all
    &lt;/Location>
  Alias /struts-example "$TOMCAT_HOME/webapps/struts-example"
    &lt;Directory "$TOMCAT_HOME/webapps/struts-example>
      Options Indexes FollowSymLinks
    &lt;/Directory>
      ApJServMount /struts-example/servlet /struts-example
    &lt;Location "/struts-example/WEB-INF/">
      AllowOverride None
      deny from all
    &lt;/Location>
  </pre>
  <ul>
    <li>The generated file above does not know anything 
      about extension mappings defined in a web.xml file, so the "*.do" URIs that 
      go to the controller servlet will not be recognized. To fix this, add the 
      following line to the saved version of "tomcat-apache.conf", after the 
corresponding 
      line for the .jsp extension:<br/>
      <code>AddHandler jserv-servlet .do</code></li>
    <li>Ensure that the saved version of "tomcat-apache.conf" is referenced in your 
      Apache "httpd.conf" configuration file. A typical use would have the following 
      line at the bottom of "httpd.conf":<br/>
      <code>Include /usr/local/apache/conf/tomcat-apache.conf</code></li>
    <li>In order to recognize "index.jsp" as a default page for web applications, 
      search in your "httpd.conf" for a "DirectoryIndex" directive. If you have 
      one, add "index.jsp" to the end of the list, so that it might look like 
this:<br/>
      <code>DirectoryIndex index.html index.jsp</code><br/>
      If you do not have such an entry, add one like this:<br/>
      <code>DirectoryIndex index.jsp</code></li>
    <li>Restart Apache to make it aware of the new applications. You should now 
      be able to access the applications from a browser like this:<br/>
      <code>http://localhost/struts-documentation<br/>
      http://localhost/struts-example</code></li>
  </ul>
    <hr/>
    <ul><li>Author: Craig R. McClanahan</li></ul>
    <hr/>
    <p>Back to <a href="installation.html#Containers">Installation</a></p>
  </section>
  </body>
  </document>
  
  
  
  1.1                  jakarta-struts/src/doc/installation-ubs.xml
  
  Index: installation-ubs.xml
  ===================================================================
  <?xml version="1.0"?>
  <document url="./installation-ubs.xml">
  
    <properties>
      <author>Mike Schachter</author>
      <title>The Struts Framework Project - Installation - Bluestone UBS</title>
    </properties>
  
    <body>
  
  <section name="Installing Struts with your servlet container" href="Containers"> 
  
  <h3><a name="ubs72">Bluestone Universal Business Server 7.2</a></h3>
  
  <ul>
    <li>You need UBS version 7.2 to run war file applications. The UBS 7.2.2 
evaluation 
      is located <a 
href="http://www.bluestone.com/SaISAPI.dll/SaServletEngine.class/products/downloads.jsp">here</a>.
 
      If you're using version 7.2.1, you need to download the WAR file patch, located 
      in the product enhancement section of Bluestone's website <a 
href="http://www.bluestone.com/SaISAPI.dll/SaServletEngine.class/products/wfe.jsp">here</a>
 
    </li>
    <li> After installation of the correct version and/or patch of UBS 7.2, you 
      need to modify your apserver.txt file to point to the correct directory for 
      your war file applications. Look for the section that says something similar 
      to the following:<br />
      <pre>
    [SaServletEngine.class]
    session_affinity=1
    type=1
    program=/SaServletEngine.class
    file_path=f:\webapps
    host=localhost:20000
  </pre>
    </li>
  
    <li>Use the directory specified by the "file_path" variable, or modify it to 
      point to your own custom webapp directory. Copy the "struts-documention.war" 
      and "struts-example.war" files into that webapp directory, and start the UBS 
      (read documentation distributed with UBS for information on how to start it 
      if necessary). Your webapps are now accessible from the following URL: 
      <p align="center"> 
http://localhost/&lt;PLUGIN&gt;/SaServletEngine.class/struts-example/<br />
        http://localhost/&lt;PLUGIN&gt;/SaServletEngine.class/struts-documentation/ 
      </p>
    </li>
  
    <li> Note: "&lt;PLUGIN&gt;" represents the plugin you are using for your specific 
      webserver. For apache on Windows, it might be "cgi-bin/SaCGI.exe", for IIS 
      on Windows, it might be "scripts/SaCGI.exe" or "scripts/ISAPI.dll". Consult 
      the UBS documentation for more information. </li>
  </ul>
    <hr/>
     <ul>
      <li>Author: Mike Schachter</li>
    </ul>
    <hr/>
    <p>Back to <a href="installation.html#Containers">Installation</a></p>
  </section>
  </body>
  </document>
  
  
  
  1.1                  jakarta-struts/src/doc/installation-was.xml
  
  Index: installation-was.xml
  ===================================================================
  <?xml version="1.0"?>
  <document url="./installation-was.xml">
  
    <properties>
    <author>dIon Gillard</author>
      <title>The Struts Framework Project - Installation - WebSphere Application 
Server</title>
    </properties>
  
    <body>
  
  <section name="Installing Struts with your servlet container" href="Containers"> 
  
  <h3><a name="was352">WebSphere Application Server 3.5 FixPack 2</a></h3>
  
  <ul>
  <li>In the steps below, <code>$WAS_HOME</code> refers to the directory in which you
    have installed WebSphere Application Server, and <code>$STRUTS_HOME</code> is the 
    directory in which you unpacked the Struts binary distribution.</li>
  
  <li>WebSphere before 3.5.2 did not support JSP 1.1 and Servlet 2.2, which 
    made it difficult to get Struts functioning without massive code changes. 
    Please upgrade to 3.5.2 (3.5 with FixPack 2)  before attempting to use 
    Struts. See <a 
href="http://www.ibm.com/software/webservers/appserv/efix.html">http://www.ibm.com/software/webservers/appserv/efix.html</a>
    for download and install instructions on FixPack 2 for WebSphere 3.5</li>
   
  <li>Warning: Struts will not work with WebSphere 3.5.2 out of the box. Fixes 
    expected to be in WebSphere 3.5.3 (not released at time of writing) should 
    correct this. However, you can successfully get WebSphere 3.5.2 working 
    with Struts.</li>
   
  <li>Make sure the WebSphere Application Server is started. Under Windows 
    NT/2000, it's the "IBM WS AdminServer" service.</li>
   
  <li>Start the WebSphere Administrative Console.</li>
  
  <li>Once it's started, select "Convert a War File" from the tasks toolbar 
    option, or from the Console->Tasks menu. This will cause a "Convert War 
    File" Wizard dialog to appear.</li>
   
  <li>Select a Servlet Engine to host the web application that will result 
    from converting the War file, e.g. "Default Servlet Engine", by expanding 
    the tree control under Nodes. Press the Next button.</li>
   
  <li>Select a Virtual Host to associate the resulting web application with, 
    e.g. "default host". Press the Next button.</li>
   
  <li>Press the Browse button and choose the 
    <code>$STRUTS_HOME/webapps/struts-example.war</code>. Press the Next button</li>
   
  <li>Select a destination directory for the resulting web application, e.g.
    <code>$WAS_HOME/hosts/default_host</code>. Press the Next button</li>
  
  <li>Enter a "Web Application Web Path", e.g. struts-example, and a "Web 
    Application Name", e.g. struts-example. Press the Finish button.</li>
   
  <li>You should, after a lengthy pause, get a message box with the text
    Command "convert war file" completed successfully. Press Ok.</li>
   
  <li>You now need to add jaxp.jar and a jaxp compatible parser, e.g. 
    parser.jar from JAXP 1.0.1 to the struts-example web application's 
    servlets directory, e.g.
    <code>$WAS_HOME/AppServer/hosts/default_host/struts-example/servlets</code></li>
   
  <li>At this point, if WAS 3.5.2 correctly implemented Servlet 2.2, all 
    would be fine. However, WAS 3.5.2  returns null for calls to 
    <code>ServletContext.getResource(String)</code> or 
    <code>ServletContext.getResourceAsStream(String)</code>. This manifests itself as 
an 
    exception in the application server stdout log, e.g. 
    <code>default_server_stdout.log.</code></li>
   
  <li>Warning: Don't be fooled by the fact that the web application starts 
    successfully from the Admin Console. It actually doesn't. The Admin 
    Console is lying. If you try to access the webapp
    e.g. <code>http://localhost/struts-example/</code> it will fail.</li>
   
  <li>At this point, you need to patch the Struts source. There are three 
    places <code>getResourceAsStream</code> is called:</li></ul>
   <pre>
      ResourceTag.doStartTag()
      ActionServlet.initMapping()
      PropertyMessageResources.loadLocale(String)
  </pre> 
    <p>of these, <code>ActionServlet</code> is the most important.</p>
   
  <ul><li>Change the source from</li></ul>
  <pre>
      // Acquire an input stream to our configuration resource
      InputStream input = getServletContext().getResourceAsStream(config);
  </pre>
  <p>to</p>
  <pre>
      // Acquire an input stream to our configuration resource
      InputStream input = new 
        java.io.FileInputStream(getServletContext().getRealPath(config));
   </pre>
  <ul><li>  Make similar changes to the other classes if necessary.</li>
   
  <li>Recompile ActionServlet and copy the <code>.class</code> file to <br/>
  
  <code>$WAS_HOME/AppServer/hosts/default_host/struts-example/servlets/<br/>
  org/apache/struts/action/ActionServlet.class</code></li>
  
  <li>Another bug with WAS 3.5.2's classloaders is that Class.getResource() 
    wont load a resource from a jar, so you must copy<br/>
    <code>$STRUTS_HOME/lib/struts-config_1_0.dtd</code> <br/>
    to <br/>
    
<code>$WAS_HOME/AppServer/hosts/default_host/struts-example/servlets/org/apache/struts/resources/struts-config_1_0.dtd</code><br/>
    or be connected to the Internet to fetch the dtd from the jakarta web site.</li>
  
  <li>Start your webapp in the Admin Console</li>
  
  <li>Test the example application by loading the following URL in your 
    browser of choice: <a 
href="http://localhost/struts-example/">http://localhost/struts-example/" 
>http://localhost/struts-example/</a></li>
  </ul> 
    <hr/>
    <ul><li>Author: dIon Gillard</li></ul>
    <hr/>
    <p>Back to <a href="installation.html#Containers">Installation</a></p>
  </section>
  </body>
  </document>
  
  
  

Reply via email to