Router Configuration
The Content-based router in Order Management Server lets routing of the order to the correct destination based on the contents of the order message.
Content-based routing schedules the order of the messages that are based on the actual content of the message itself, rather than by a destination specified by the message. Content-based routing works by opening a message and applying a set of rules to its content to determine the destination of a message. By freeing the sending application from where an order might be routed for fulfillment, content-based routing provides a high degree of flexibility to configure multiple types of Orchestration engines.
Order Management Server supports two types of routers:
- Pass-through router (passthroughRouter), and
- Filter based router (filteringRouter).
To select the router type, you must be at the Order Management System level configuration:
- Go to Settings under "Hi, admin!"
- Edit router configuration.
- Select the type of router you want to use. Default router type is
passthroughRouter
A pass-through does not apply any condition on the incoming order message and passes the message to the default Orchestrator.
The following table shows configurable parameters for Filter based Router.
Parameters | Description |
---|---|
Router Condition | XPath filter condition to be applied on the incoming order message. If the XPath condition is not satisfied, the message is routed to the default Orchestrator or else the message is routed to the iProcess Conductor destination. |
Orchestrator Submit Order Queue | Destination queue name of the orchestrator for submit order request. |
Orchestrator Amend Order Queue | Destination queue name of the orchestrator for amend order request. |
Orchestrator Suspend Order Queue | Destination queue name of the orchestrator for suspend order request. |
Orchestrator Activate Order Queue | Destination queue name of the sfor activate order request. |
iProcess Conductor Orchestrator Submit Order Queue | Destination queue name of iProcess Conductor for submit order request. |
iProcess Conductor Orchestrator Amend Order Queue | Destination queue name of iProcess Conductor for amend order request. |
iProcess Conductor Orchestrator Suspend Order Queue | Destination queue name of iProcess Conductor for suspend order request. |
iProcess Conductor Orchestrator Activate Order Queue | Destination queue name of iProcess Conductor for activate order request. |
Filtering Router
A filter condition for a router is applied only for a submit order request. Any subsequent request related to the order is always routed through the same orchestrator where the original submit order request was submitted. The XPath conditions specified must be based on the Order schema.
For example, XPath /SubmitOrderRequest/orderRequest/header/udf[name='Orchestrator']/value/text() specified for a filter condition results in sending all the orders containing User Defined Field with name value pair 'Orchestrator' and iProcess Conductor' to TIBCO iProcess Conductor. It is not required to be based on the User Defined Field element. The only requirement is that it might be a valid XPath condition on the order schema. TIBCO Order Management supports specifying a filter condition but it does not perform any validation on the XPath condition. It must be validated before specifying it in the TIBCO Order Management Configurator.
- Any XPath filter condition results in the Orchestrator name.
- Orchestrator names are case sensitive. The Order Management Server router matches the text value to the Orchestrator name (case sensitive). If the text value is iProcess, the order is routed to the AFO Orchestrator.
The router uses an XML configuration to configure the routing and mediation rules, which are added to a
router-context.xml
of the Order Management Server component. This file is available inside
$OM_HOME/roles/omsServer/standalone/services/omsServer/omsServer-5.0.0-SNAPSHOT.jar.
The following example shows a router configuration to route the order message to Business Events (BE) Orchestrator based on the User Defined Field value in the order message:
/SubmitOrderRequest/orderRequest/header/udf[name='Orchestrator']/value/text()