Introduction: Web applications

Explore the key concepts pertaining to Web applications. Web applications are comprised of one or more related files that you can manage as a unit, including HTML files, servlets, and Java ServerPages (JSP) files. IBM extensions to the JSP specification make it easy for HTML authors to add the power of Java technology to Web pages, without being experts in Java programming.

Web applications

A Web application is comprised of one or more related servlets, JavaServer Pages technology (JSP files), and Hyper Text Markup Language (HTML) files that you can manage as a unit.


Servlets are Java programs that use the Java Servlet Application Programming Interface (API). You must package servlets in a WAR file or Web module for deployment to the application server. Servlets run on a Java-enabled Web server and extend the capabilities of a Web server, similar to the way applets run on a browser and extend the capabilities of a browser.

Application life cycle listeners and events

With application life cycle listeners and events, which are now part of the Servlet API, you can notify interested listeners when servlet contexts and sessions change. For example, you can notify users when attributes change and if sessions or servlet contexts are created or destroyed.

Servlet filtering

Servlet filtering provides a new type of object called a filter that can transform a request or modify a response. You can chain filters together so that a group of filters can act on the input and output of a specified resource or group of resources.

Page lists

Page lists allow you to avoid hard-coding Uniform Resource Locators (URLs) in servlets and JSP files. A page list specifies the location where a request is to be forwarded, but automatically customizes that location depending on the MIME type of the servlet. Use these properties to specify a markup language and an associated MIME type. For the given MIME type, you also specify a set of pages to invoke.

Client type detection support

In addition to providing the page list mapping capability, the PageListServlet also provides Client Type Detection support. A servlet determines the markup language type that a calling client needs in the response, using the configuration information in the client_types.xml file.

autoRequestEncoding and autoResponseEncoding

Starting with WAS V5, the Web container no longer automatically sets request and response encodings, and response content types. Programmers are expected to set these values using available methods in the Servlet 2.3 Specification or later. If programmers choose not to use the character encoding methods, they can specify the autoRequestEncoding and autoResponseEncoding extensions, which enable the application server to set the encoding values and content type.

JavaServer Pages

JSP are application components coded to the JavaServer Pages Specification. JavaServer Pages enable the separation of the Hypertext Markup Language (HTML) code from the business logic in Web pages so that HTML programmers and Java programmers can more easily collaborate in creating and maintaining pages.

Web modules

A Web module represents a Web application. A Web module is created by assembling servlets, JSP files, and static content such as Hypertext Markup Language (HTML) pages into a single deployable unit. Web modules are stored in WAR files, which are standard Java archive files.

Security constraints

Security constraints determine how Web content is to be protected. These properties associate security constraints with one or more Web resource collections. A constraint consists of a Web resource collection, an authorization constraint and a user data constraint.

File serving

File serving allows a Web application to serve static file types, such as HTML. File-serving attributes are used by the servlet that implements file-serving behavior.


A session is a series of requests to a servlet, originating from the same user at the same browser.

Session management support

WebSphere Application Server provides facilities, grouped under the heading Session Management, that support the javax.servlet.http.HttpSession interface described in the Servlet API specification.

Distributed sessions

The product provides database session persistence and memory-to-memory session replication in a distributed environment.

Memory-to-memory replication

WebSphere Application Server supports session replication to another WAS profile. This support is referred to as memory-to-memory session replication. In this mode, sessions can replicate to one or more WAS profiles to address HTTP Session single point of failure (SPOF).

Memory-to-memory session partitioning

Session partitioning gives the administrator the ability to filter or reduce the number of destinations that the session object gets sent to by the replication service. You can also configure session partitioning by specifying the number of replicas on the replication domain. The Single replica option is chosen by default. Since the number of replicas is global for the entire replication domain, all the session managers connected to the replication domain use the same setting.

Base in-memory session pool size

The base in-memory session pool size number has different meanings, depending on session support configuration.

Related information
Web applications




WebSphere is a trademark of the IBM Corporation in the United States, other countries, or both.
IBM is a trademark of the IBM Corporation in the United States, other countries, or both.