NonStop Servlets for JSP System Administrator's Guide

NonStop Servlets for JavaServer Pages (NSJSP) System Administrator’s Guide525644-001
4-1
4
Programming and Management
Features
The information discussed in this section includes the following:
Client Programming Features on page 4-1
Servlet Programming Features on page 4-2
The NSJSP Manager Web Application on page 4-8
Client Programming Features
This subsection describes how to refer to a servlet in an HTML document and how to
send requests to and receive responses from a servlet. To an HTML document or a
web client, there is very little difference between using a servlet and using any other
type of CGI application.
Before you read this, you should be familiar with the information in the iTP Secure
WebServer System Administrator’s Guide.
This subsection describes the following topics:
Invoking a Servlet on page 4-1
Passing Request Information on page 4-1
Receiving Response Information on page 4-2
Invoking a Servlet
You invoke a servlet by including a reference to its URL. The syntax of a servlet URL is
described in Map Requests to Applications and Servlets on page 3-15.
Passing Request Information
You can pass request information to a servlet by any of the following means:
Query strings appended to URLs. The servlet receives this data through the
QUERY_STRING environment variable.
Extra path information appended to URLs. The servlet receives this information
through the PATH_INFO and PATH_TRANSLATED environment variables.
HTML forms. A servlet receives data from HTML forms in an input stream.
A servlet accesses environment variables and the input stream through an object, as
described in Using the Servlet API on page 4-4.