Configuring routing for subscribers involves setting up rules that determine how incoming
messages are directed to specific services or workflows based on message content or metadata. By
using conditional logic, subscribers can intelligently route messages to the appropriate processing
logic, enabling more efficient and scalable integration flows.
Before you begin
Ensure that a subscriber is created. For more information, see Creating subscribers.
Procedure
- From
, click the
subscriber.
The Subscriber details page is
displayed.
- Click Add routing rule.
The New
routing rule page is displayed.
- Enter the following details:
Repeat this step to add more routing
rules.
- Name
- Name for the routing rule. This name must be unique for each routing rule. It is used to
identify the routing rule in other parts of the application.
- Filter
- Expression that must be evaluated before the invocation is run. If you do not specify any
expression, the default routing rule is considered.
Note: The logical operators in an
expression must be written in lowercase. For example, %string/body%=="Hello" or
%string/body%=="Hi".
- Invocation type
- Type of the invocation (workflow or a flow service) that must be started when a message arrives.
For more information, see Configuring messaging service trigger for subscribing messages.
- Select Invocation
- Name of the invocation that must be started. You can create a new invocation if none of the
existing ones suffice by clicking Add in the Select
Invocation row.
- Click Add.
The newly added rule is displayed
under Routing rules.
- Click Save.
The subscriber details
appear.
Results
The subscriber is configured with routing rules.
What to do next
- Edit or delete a routing rule
- You can edit or delete a routing rule by clicking the Edit or
Delete buttons that are next to the rule in the Subscriber
details page.
- Reorder routing rules
- The system evaluates the routing rules in the same order in which the rules appear under Routing
rules. However, you can reorder the rules based on your needs by doing the following steps in the
Subscriber details page:
- Select a routing rule.
- Move the selected rule up or down the list to the wanted position