XML request and response processing

You are recommended to use IBM® Developer for Z or the CICS Web services assistant as the strategic method for parsing modeled requests. This approach provides XML parsing and generation for both the request header and body.

The CICS Web services assistant is described in detail in The CICS web services assistant. For information on using the tooling to perform XML processing, see the IBM Developer for Z help that is provided with the tool.

For backwards compatibility, CICS Service Flow Runtime provides an internal XML parsing function, which is nonstrategic.

XML request and response support consists of two main functions:

  1. The XML parsing function parses an inbound XML request message and maps XML elements to a fixed format COMMAREA. See XML message formats for a sample of a request message in XML format.
  2. The XML generation function generates an XML response message from a fixed format COMMAREA.
Figure 1. XML request and response processing
Diagram shows an XML request message flowing into the CICS Service Flow Runtime, where it is being converted to a fixed format request message for processing. On the return response message, the diagram shows a fixed format response message being converted to an XML response message and being returned as an XML response message to the service requestor.
In the runtime environment, the processing associated with XML request and response messages varies according to the way the service requester incorporates the XML into the request message. The request message can be divided into two main parts:
  • The message header DFHMAH
  • The application data
For more information, see Sending the request message in a COMMAREA.
The following table indicates the message composition formats for XML requests and whether or not the runtime environment supports the message composition format:
Table 1. Supported XML message composition
XML location Supported
In the message header and in the application data Yes
In the application data only Yes
In the message header only No

See XML message formats for samples of the XML that can be used in request and reply messages.