IBM Integration Bus, Version 9.0.0.5 Operating Systems: AIX, HP-Itanium, Linux, Solaris, Windows, z/OS

See information about the latest product version

Configuring the message map to include the SOAP message

In IBM® Integration Bus, a SOAP message is described by a generic model that includes the SOAP Envelope and optionally Attachments. You define your SOAP message parts in a message map by using the Cast function.

A SOAP message consists of an Envelope and optionally Attachments. The envelope contains a SOAP header and a SOAP body. A SOAP body can include SOAP faults.

In IBM Integration Bus, when you use SOAP nodes, a SOAP message is described by a generic model. For more information, see SOAP tree overview.

In addition to the standard SOAP parts, the SOAP message generic model includes a Context part that includes contextual information about the current SOAP message being processed. This is the only part in a message map whose structure is included automatically. You must define the other SOAP message parts manually by using the Cast function.

The following table compares the SOAP message structure with the IBM Integration Bus SOAP message generic model:

Table 1. Comparison between the SOAP message structure and the IBM Integration Bus SOAP message representation
Standard SOAP message parts Status IBM Integration Bus SOAP message parts IBM Integration Bus Status
    Context Required
SOAP header (part of the SOAP envelope) Optional Header (part of the SOAP_Domain_Msg) Optional
SOAP body (part of the SOAP envelope) Required Body (part of the SOAP_Domain_Msg) Required
SOAP faults (part of the SOAP body) Optional Fault (part of the Body) Optional
SOAP Attachments Optional Attachment (part of the SOAP_Domain_Msg) Optional

In this scenario, you will learn how to configure your message map to map the standard SOAP message parts which make up the SOAP_Domain_Msg.

Complete the following steps to configure the SOAP_Domain_Msg when the Mapping node is connected directly from a SOAPInput node with no SOAPExtract node:

  1. Define a Move transform between the input Context object and the output Context object.
  2. Define a Move transform between the input Header object and the output Header object.

    The following figure shows the message map after you define a Move transform to copy the Header.

    This figure shows the Move transform between the input Header object and the output Header object, and the Move transform between the input and output Context folder.

    The SOAP Header element contains application-specific information, including attributes that define how you should process the SOAP message.

  3. Define the transformation for the Body object.

    You define SOAP body parts by using the Cast function. You can cast attributes and other body parts. Then, define transforms between the input elements and the output elements in each body part that you have added.

    Complete the following steps to define the SOAP body parts and their transformations:

    1. Cast the SOAP body xsd:any element into a specific type. For more information, see Casting the SOAP body into a specific type.
    2. Cast a SOAP body base type element to a derived type element. A derived type element is also known as an extension type element. For more information, see Configuring derived types in the SOAP body.

      In a message map, you cast a base type to a derived type or extension type so that you can define transformations between subtypes of a data type. For example, addresses are represented differently for different countries. You might want to map addresses from different countries into a common complex structure for addresses.

    3. Create and configure the If, Else if, and Else transform to control the flow of the mapping between elements defined as a specific or a derived type in the input and output message assembly by setting conditions. For more information, see Configuring an If, Else if, and Else transform in a message map.
  4. Define a Move transform between the input Attachment object and the output Attachment object.

Your have configured a message map that transforms a SOAP message.

When you use an If, Else if, and Else transform between your SOAP_Domain_Msg input object and SOAP_Domain_Msg output object, you must manually configure each element in the SOAP_Domain_Msg. You must map each element in the SOAP_Domain_Msg input object to the corresponding output object so that you do not loose the information of the element.
Note: Elements that are part of the input object and do not have a transform defined to an output object are deleted from the output structure and their value is lost.

You now have a message map that transforms address data, based on the country of the address. The message map contains a nested map that uses the If, Else if, and Else transform that you defined.

The following figure shows the message map after you complete the previous steps:

This figure shows the message map after the If, Else if, and Else transform is configured.

You have successfully completed the scenario. Your map is now ready to use.


scnmap_03_17_.htm | 
        
        Last updated:
        
        Last updated: 2016-08-12 11:20:26