DFHWBERX uses the EXEC CICS® WEB and DOCUMENT application programming
interfaces to obtain information about the Web client's request and create
and send the error response. It is called as an application program. DFHWBERX
can be specified by an analyzer program, or as the PROGRAM attribute in a
URIMAP definition if an error response is always wanted for the request.
Attention: This topic contains Product-sensitive Programming Interface
and Associated Guidance Information.
DFHWBERX
is used when the CICS-supplied default analyzer DFHWBAAX is specified as the
analyzer program on the TCPIPSERVICE definition, and no matching URIMAP definition
is found for a request. DFHWBAAX sets DFHWBERX as the application program
to handle the request, using the wbra_server_program output
parameter.
DFHWBERX is user-replaceable. CICS supplies the source code for DFHWBAAX
in Assembler only.
DFHWBERX does not use information provided in a COMMAREA,
and does not receive a default HTTP response from CICS. Instead, it uses EXEC CICS commands
to obtain information about the Web client's request and create and send the
error response. This means that CICS can give DFHWBERX more assistance
with the composition of the response.
DFHWBERX provides an error response
as follows:
- If the Web client's request is a POST request with media type text/xml,
it is assumed to be a SOAP 1.1 request, and a SOAP 1.1 fault response is returned.
- If the request is a POST request with media type application/soap+xml,
it is assumed to be a SOAP 1.2 request, and a SOAP 1.2 fault response is returned.
- All other requests are assumed to be a standard HTTP request, so a suitable
HTTP response is composed and returned with a 404 (Not Found) status code.
In DFHWBERX:
- The EXEC CICS WEB
EXTRACT command is used to obtain the URL of the Web client's request for
which an error response is needed.
- EXEC CICS DOCUMENT
commands are used to construct the message body.
- For SOAP fault responses, the EXEC CICS WEB WRITE HTTPHEADER command is used
to write an appropriate SOAP action header.
- The EXEC CICS WEB
SEND command is used to specify an appropriate status code and send the response
to the Web client. The UTF-8 character set is specified for code page conversion
of the response body.