Figure 1 shows two MessageTypes that can be used to define the information exchanged between
service consumers and providers. These MessageTypes can be used as types for operation parameters.
Figure 1. Sample MessageType diagram
MessageTypes can have associations with other message and data types as shown by the
relationship between POMessage and Customer. Such associations must be aggregations.
Figure 2 shows two examples of the Purchasing Interface and its
processPurchaseOrder Operation. The first example uses document or message style parameters where the types of the
parameters are the MessageTypes shown above. The second version uses more "Object Oriented" Remote Procedure Call (RPC)
style that supports multiple inputs, outputs, and a return value. The choice to use depends on modeler preference and
possibly the target platform. Some platforms such as Web Services and WSDL require message style parameters, which can
be created from either modeling style. It is possible to translate RPC style to message parameters in the transform,
and that's what WSDL wrapped doc-literal message style is for. But this can result in many WSDL messages containing the
same information that could cause interoperability problems in the runtime platform.
Figure 2. Document-style (top) vs. RPC-style (bottom) messages
|