You can send further requests without waiting for a response
from the server. This technique is known as pipelining. The WEB SEND
command is used for sending pipelined requests. You cannot use the
WEB CONVERSE command because that command includes waiting for a
response.
About this task
How CICS web support handles pipelining
has more detailed information.
The
HTTP/1.1 specification states that your sequence of pipelined requests
must be idempotent; that is, if you repeat all or part of the sequence,
the same results are obtained.
Pipelining
has more information about idempotency.
Procedure
-
Make sure that you have a persistent connection with the
server.
The HTTP/1.1 specification allows you to make one
attempt to send a pipelined sequence without checking that the connection
is persistent. If this attempt fails, you must check before trying
the requests again. To determine the nature of the connection:
-
If you specified the HTTPVNUM and HTTPRNUM options on
the WEB OPEN command for the connection, examine the returned
information
to determine the HTTP version of the server.
-
If you did not specify those options on the WEB OPEN
command, use the WEB EXTRACT command to determine the HTTP version
of the server.
-
If you have received a previous response from the server,
use the WEB READ HTTPHEADER command to check whether the server sent
a Connection: close or a Connection: Keep-Alive header.
Servers that are at HTTP/1.1 level and
do not
send a
Connection: close header, and servers that are at HTTP/1.0 level and
do
send
a Connection: Keep-Alive header, support persistent connections.
CICS does not carry out this check on your behalf, because
CICS
cannot determine whether a client application program is sending a
pipelined sequence of requests, because a pipelined request has no
special headers to identify it.
-
Do not specify CLOSESTATUS(CLOSE) on any of the requests,
except the final request in the pipelined sequence if you are not
using connection pooling and want the server to close the
connection.
If you are using connection pooling, do not specify
CLOSESTATUS(CLOSE)
at all.