InfoCenter Home >
4: Developing applications >
4.2: Building Web applications >
4.2.1: Developing servlets >
4.2.1.3: Servlet content, examples, and samples >
4.2.1.3.4: Filtering and chaining servlets >
4.2.1.3.4.2: Servlet filtering with servlet chains
4.2.1.3.4.2: Servlet filtering with servlet chains
To configure a servlet chain, you must use an IBM supplied servlet named
com.ibm.websphere.servlet.filter.ChainerServlet
- Add the com.ibm.websphere.servlet.filter.ChainerServlet to your
Web application during the application assembly stage and assign a servlet URL to the
servlet instance.
- Define the following
initialization parameter and value for the ChainerServlet:
Parameter |
Value |
chainer.pathlist |
/first_servlet_URL /next_servlet_URL |
The chainer.pathlist is a space-delimited list of servlet URLs. For example, if you want the sequence of servlets to be three servlets that you added to the examples application (servletA, servletB, servletC), specify:
Parameter |
Value |
chainer.pathlist |
/servletA /servletB /servletC |
- To invoke a servlet chain, invoke the servlet URL of the ChainerServlet in your application.
|
|