2.3 Configure the Server

Once you have downloaded and installed both the Java Platform itself and a server that supports servlets and JSP, you need to configure your server to run on your system. This configuration involves the following generic steps; the following three sections give specific details for Tomcat, JRun, and Resin.

Please note that these directions are geared toward using the server as a standalone Web server for use in desktop development. For deployment, you often set up your server to act as plugin within a traditional Web server like Apache or IIS. This configuration is beyond the scope of this book; use the wizard that comes with the server or read the configuration instructions in the vendor's documentation.

  1. Identifying the SDK installation directory. To compile JSP pages, the server needs to know the location of the Java classes that are used by the Java compiler (e.g., javac or jikes ). With most servers, either the server installation wizard detects the location of the SDK directory or you need to set the JAVA_HOME environment variable to refer to that directory. JAVA_HOME should list the base SDK installation directory, not the bin subdirectory.

  2. Specifying the port. Most servers come preconfigured to use a nonstandard port, just in case an existing server is already using port 80. If no server is already using port 80, for convenience, set your newly installed server to use that port.

  3. Making server-specific customizations. These settings vary from server to server. Be sure to read your server's installation directions.

Core Servlets and JavaServer Pages (Vol. 1.Core Technologies)
Core Servlets and Javaserver Pages: Core Technologies, Vol. 1 (2nd Edition)
ISBN: 0130092290
EAN: 2147483647
Year: 2002
Pages: 194

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net