Home TOC |
![]() ![]() ![]() |
Web Applications
A Web application is a dynamic extension of a Web server. A Web application can consist of dynamic Web pages containing various types of markup language (HTML, XML, and so on) as well as static resources such as images. A Web application can also be the endpoint of a fine-grained Web service that is used by the dynamic Web pages. In the Java 2 Platform, Web components provide the dynamic extension capabilities for a Web server. Web components are supported by the services of a runtime platform called a Web container. In the Java Web Services Developer Pack (Java WSDP), Web components are either Java Servlets or JSP pages and they run in the Tomcat Web container.
Servlets are Java programming language classes that dynamically process requests and construct responses. JSP pages are text-based documents that execute as servlets but allow a more natural approach to creating static content. Although servlets and JSP pages can be used interchangeably, each has its own strengths. Servlets are best suited to managing the control functions of an application, such as dispatching requests and handling nontextual data. JSP pages are more appropriate for generating text-based markup such as HTML, SVG, WML, and XML.
This chapter describes the organization of, configuration of, and installation and deployment procedures for Web applications. Chapters 13 and 14 cover how to develop the Web components. Many features of JSP technology are determined by Java Servlet technology, so you should familiarize yourself with that material even if you do not intend to write servlets.
Most Web applications use the HTTP protocol, and support for HTTP is a major aspect of Web components. For a brief summary of HTTP protocol features see HTTP Overview.
In This Chapter
- Web Application Life Cycle
- Web Application Archives
- WAR Directory Structure
- Tutorial Example Directory Structure
- Creating a WAR
- Configuring Web Applications
- Prolog
- Alias Paths
- Context Parameters
- Event Listeners
- Filter Mappings
- Error Mappings
- References to Environment Entries, Resource Environment Entries, or Resources
- Installing Web Applications
- Deploying Web Applications
- Listing Installed and Deployed Web Applications
- Running Web Applications
- Updating Web Applications
- Reloading Web Applications
- Redeploying Web Applications
- Removing Web Applications
- Undeploying Web Applications
- Internationalizing and Localizing Web Applications
- Accessing Databases from Web Applications
- The Examples
- Installing and Starting the Database Server
- Populating the Database
- Configuring the Web Application to Reference a Database
- Configuring Tomcat to Map the JNDI Name to a Database
Home TOC |
![]() ![]() ![]() |