This topic applies only to the IBM Business Automation Workflow Advanced
configuration.

Routing Messages Within a Mediation Flow

There are several mediation primitives that can be used for routing messages in a mediation flow.
Most mediation primitives have one input terminal (in), one fail terminal (fail), and one or more output (out) terminals, as shown in Figure 1. The in terminal is wired to accept a message and the other terminals are wired to distribute messages. If a failure occurs, the fail terminal distributes the original message, together with any failure information.
Figure 1. Mediation primitive

mediation primitive with two out terminals, and a fail terminal
Figure 1 shows that a mediation primitive with two out terminals and one fail terminal. A mediation primitive can be wired within mediation flows to specify the potential paths to which a message can be distributed. The actual path for a message is dependent on the mediation primitive. There are different paths a message can take within a mediation primitive:
  • Messages might leave an out terminal one or more times.
  • Messages might leave the fail terminal once.
  • Messages might not leave any of the terminals.

Flow branching

Figure 2. Branched mediation primitive

mediation primitive with a branched out terminal going to two services.

Figure 2 shows how a mediation primitive can have multiple wires from one output terminal branching to several services. You cannot specify the order in which messages will leave the terminal. If you need to send the message through a specific wire first, then you must use multiple output terminals each with a single wire. You can also select a mediation primitive that will allow you to control the order in which output terminals are invoked (for example see Figure 3).