LibraryLink ToToggle FramesPrintFeedback

XPath Splitter

A splitter is a type of router that splits an incoming message into a series of outgoing messages, where each of the messages contains a piece of the original message. The EIP XPath splitter pattern is restricted to using the InOnly and RobustInOnly exchange patterns. The expression that defines how to split up the original message is defined in the XPath language.


The eip:xpath-splitter element supports a forwardAttachments attribute and a forwardProperties attribute, either of which can be set to true, if you want the splitter to copy the incoming message's attachments or properties to the outgoing messages.

For each outgoing message, the XPath splitter sets the following properties:

The following example shows how to define a splitter using the EIP service engine. The specified XPath expression, /*/*, would cause an incoming message to split at every occurrence of a nested XML element (for example, the /foo/bar and /foo/car elements would be split into distinct messages).

<eip:xpath-splitter service="test:xpathSplitter" endpoint="endpoint" 
                    xpath="/*/*" namespaceContext="#nsContext">
  <eip:target>
    <eip:exchange-target uri="service:http://test/router" />
  </eip:target>
</eip:xpath-splitter>

The following table lists attributes of <eip:xpath-splitter>:


The following table lists elements of <eip:xpath-splitter>: