XML response processing for non-passthrough

At run time, XML response processing is initiated when the server adapter passes the reply data from the CICS® target application to the DPL stub program DFHMADPL.

DFHMADPL constructs a reply consistent with the format of the request message. When the request message is an XML document (i.e. the header in XML format), then the reply will be a complete XML document. When only the application data is XML, then the reply will be constructed with a standard format header and the application data as an XML document.

Processing is as follows:
  1. The server adapter passes the response data to DFHMADPL.

    Since flow composition allows multiple Output Terminals, the response could be one of several different messages.

  2. DFHMADPL constructs a response by performing the following steps:
    1. Calls the Application Data COBOL to XML Converter program.
      The purpose of this program is to place the proper XML tags around the application data that resides in the response message:
      <dfhmaad>
      Application data from response message
      </dfhmaad>

      The Application Data COBOL to XML Converter program is a user defined program. The program name is specified on the Output Terminal of the flow model, and is generated into corresponding code of the server adapter. This value is set in a manner consistent will other property values captured in the Service Flow Modeler in the WebSphere® Developer for System z® product. See the Service Flow Modeler documentation in the WebSphere Developer for System z product for information on setting properties for Adapter services.

      If an Application Data COBOL to XML Converter program name is not provided for a reply message, the application data will remain in standard, flat format.

      If the program call to the user converter program is unsuccessful, an error message will be returned to the service requestor

      The call interface for the Application Data COBOL to XML Converter program is identical to that of the Application Data XML to COBOL converter program. See Figure 1.

    2. Calls the COBOL to XML Converter program DFHMAXMO. DFHMAXMO performs the following steps:
      1. Converts the structure of the header in the response message from a flat (COBOL) format to an XML format.
      2. Places the XML declaration at the top of the XML message.

        The XML declaration was saved by the XML Header Converter program DFHMAXMI on the inbound request. That declaration was saved by the DPL stub program.

      3. Takes the reply data formatted by the user defined Application Data COBOL to XML Converter program and converts it to XML.
      4. DFHMAXMO reports any errors it encounters to the CICS system log, under the CEEMSG section. Errors written to the CICS system log are returned to the service requestor.
Figure 1. XML Response processing
Diagram shows the processing that is performed by the DPL Stub program to support an XML reply to the service requestor.