choice flow control

13
Choice Flow Control Reference The choice flow control dynamically routes messages based on message payload or properties. It adds conditional programming to a flow, similar to an if/then/else code block.

Upload: ramakrishna-kapa

Post on 08-Jan-2017

64 views

Category:

Technology


0 download

TRANSCRIPT

Page 1: Choice flow control

Choice Flow Control Reference

The choice flow control dynamically routes messages based on message payload or

properties. It adds conditional programming to a flow, similar to an if/then/else code block.

Page 2: Choice flow control

• A choice flow control uses expressions to evaluate the content of a message, then it routes the message to one of the routing options within its scope (see image below). It directs messages to the first routing option in the scope that matches the routing configurations (evaluates to true). If none of expressions evaluate to true, the choice flow control directs the message to the default (else) route.

Page 3: Choice flow control
Page 4: Choice flow control

Configuring the Choice Flow Control

• To configure the choice flow control, you need to determine the following message routing details:

• Content the choice flow router should evaluate to determine routing

• Number of routing options with which to supply the choice flow control

• What processing Mule should perform for each routing option

• Default routing option

Page 5: Choice flow control
Page 6: Choice flow control
Page 7: Choice flow control
Page 8: Choice flow control
Page 9: Choice flow control
Page 10: Choice flow control

XML configuration Here

Page 11: Choice flow control

After deployed successfullyClick on the below url

• http://localhost:8081/router?language=Spanish

Page 12: Choice flow control
Page 13: Choice flow control

If you can specify only language like belowhttp://localhost:8081/router?language

It will display default as English