
Content-based routing routes the message based on the content of the message, rather than by an explicitly specified destination. The Content-based router pattern checks the content of the received message and then uses these details to get the routing information for the message. Based on the routing information, a different channel is available to send the data.
There can be a number of criteria such as existence of fields, specific field values, etc. for routing the message. To implement the Content-based router pattern, values must be available at the run time to decide the destination of the message. In this pattern, usage of business rules and dynamic send port configuration plays a key role.