camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From build...@apache.org
Subject svn commit: r907746 [2/3] - in /websites/production/camel/content: book-cookbook.html book-in-one-page.html cache/main.pageCache parallel-processing-and-ordering.html
Date Fri, 02 May 2014 09:19:51 GMT
Modified: websites/production/camel/content/book-in-one-page.html
==============================================================================
--- websites/production/camel/content/book-in-one-page.html (original)
+++ websites/production/camel/content/book-in-one-page.html Fri May  2 09:19:51 2014
@@ -785,7 +785,10 @@ disruptor-vm:someName[?<option>]
 </div></div></td><td colspan="1" rowspan="1" class="confluenceTd"><p>Working with TCP and UDP protocols using Java NIO based capabilities offered by the <a shape="rect" class="external-link" href="http://netty.io/" rel="nofollow">Netty</a> project</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p><a shape="rect" href="netty-http.html">Netty HTTP</a> / camel-netty-http</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: plain; gutter: false" type="syntaxhighlighter"><![CDATA[netty-http:http:[port]/context-path[?options]
 ]]></script>
-</div></div></td><td colspan="1" rowspan="1" class="confluenceTd"><p>Netty HTTP server and client using the <a shape="rect" class="external-link" href="http://netty.io/" rel="nofollow">Netty</a> project</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p><a shape="rect" href="optaplanner.html">OptaPlanner</a> / camel-optaplanner</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+</div></div></td><td colspan="1" rowspan="1" class="confluenceTd"><p>Netty HTTP server and client using the <a shape="rect" class="external-link" href="http://netty.io/" rel="nofollow">Netty</a> project</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p><a shape="rect" href="optaplanner.html">O</a><a shape="rect" href="openshift.html">penshift</a> / camel-openshift</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: plain; gutter: false" type="syntaxhighlighter"><![CDATA[openshift:clientId[?options]
+]]></script>
+</div></div></td><td colspan="1" rowspan="1" class="confluenceTd"><p>To manage your <a shape="rect" class="external-link" href="https://www.openshift.com/" rel="nofollow">Openshift</a> applications.</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p><a shape="rect" href="optaplanner.html">OptaPlanner</a> / camel-optaplanner</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: plain; gutter: false" type="syntaxhighlighter"><![CDATA[optaplanner:solverConfig[?options]
 ]]></script>
 </div></div></td><td colspan="1" rowspan="1" class="confluenceTd"><p>Solves the planning problem contained in a message with <a shape="rect" class="external-link" href="http://www.optaplanner.org/" rel="nofollow">OptaPlanner</a>.</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p><a shape="rect" href="pax-logging.html">Pax-Logging</a> / camel-paxlogging</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
@@ -3752,53 +3755,10 @@ from(&quot;activemq:My.Queue&quot;).
 <p>Various patterns can work with databases as follows</p>
 
 <ul><li><a shape="rect" href="idempotent-consumer.html">Idempotent Consumer</a></li><li><a shape="rect" href="aggregator.html">Aggregator</a></li><li><a shape="rect" href="bam.html">BAM</a> for business activity monitoring</li></ul>
-<h2 id="BookInOnePage-ParallelProcessingandOrdering">Parallel Processing and Ordering </h2>
-
-<p>It is a common requirement to want to use parallel processing of messages for throughput and load balancing, while at the same time process certain kinds of messages in order.</p>
-
-<h3 id="BookInOnePage-Howtoachieveparallelprocessing">How to achieve parallel processing</h3>
-
-<p>You can send messages to a number of Camel <a shape="rect" href="components.html">Components</a> to achieve parallel processing and load balancing such as</p>
-
-<ul><li><a shape="rect" href="seda.html">SEDA</a> for in-JVM load balancing across a thread pool</li><li><a shape="rect" href="activemq.html">ActiveMQ</a> or <a shape="rect" href="jms.html">JMS</a> for distributed load balancing and parallel processing</li><li><a shape="rect" href="jpa.html">JPA</a> for using the database as a poor mans message broker</li></ul>
-
-
-<p>When processing messages concurrently, you should consider ordering and concurrency issues. These are described below</p>
-
-<h4 id="BookInOnePage-Concurrencyissues">Concurrency issues</h4>
-
-<p>Note that there is no concurrency or locking issue when using <a shape="rect" href="activemq.html">ActiveMQ</a>, <a shape="rect" href="jms.html">JMS</a> or <a shape="rect" href="seda.html">SEDA</a> by design; they are designed for highly concurrent use. However there are possible concurrency issues in the <a shape="rect" href="processor.html">Processor</a> of the messages i.e. what the processor does with the message? </p>
-
-<p>For example if a processor of a message transfers money from one account to another account; you probably want to use a database with pessimistic locking to ensure that operation takes place atomically. </p>
-
-<h4 id="BookInOnePage-Orderingissues">Ordering issues</h4>
-
-<p>As soon as you send multiple messages to different threads or processes you will end up with an unknown ordering across the entire message stream as each thread is going to process messages concurrently. </p>
-
-<p>For many use cases the order of messages is not too important. However for some applications this can be crucial. e.g. if a customer submits a purchase order version 1, then amends it and sends version 2; you don't want to process the first version last (so that you loose the update). Your <a shape="rect" href="processor.html">Processor</a> might be clever enough to ignore old messages. If not you need to preserve order.</p>
-
-<h3 id="BookInOnePage-Recommendations">Recommendations</h3>
-
-<p>This topic is large and diverse with lots of different requirements; but from a high level here are our recommendations on parallel processing, ordering and concurrency</p>
-
-<ul><li>for distributed locking, use a database by default, they are very good at it <img class="emoticon emoticon-smile" src="https://cwiki.apache.org/confluence/s/en_GB-1988229788/4109/76e0dbb30bc8580e459c201f3535d84f9283a9ac.1/_/images/icons/emoticons/smile.png" data-emoticon-name="smile" alt="(smile)"></li><li>to preserve ordering across a JMS queue consider using <a shape="rect" class="external-link" href="http://activemq.apache.org/exclusive-consumer.html">Exclusive Consumers</a> in the <a shape="rect" href="activemq.html">ActiveMQ</a> component</li><li>even better are <a shape="rect" class="external-link" href="http://activemq.apache.org/message-groups.html">Message Groups</a> which allows you to preserve ordering across messages while still offering parallelisation via the <strong>JMSXGroupID</strong> header to determine what can be parallelized</li><li>if you receive messages out of order you could use the <a shape="rect" href="resequencer.html">Resequencer</a> to put them 
 back together again</li></ul>
-
-
-<p>A good rule of thumb to help reduce ordering problems is to make sure each single can be processed as an atomic unit in parallel (either without concurrency issues or using say, database locking); or if it can't, use a <a shape="rect" class="external-link" href="http://activemq.apache.org/message-groups.html">Message Group</a> to relate the messages together which need to be processed in order by a single thread.</p>
-
-<h3 id="BookInOnePage-UsingMessageGroupswithCamel">Using Message Groups with Camel</h3>
-
-<p>To use a Message Group with Camel you just need to add a header to the output JMS message based on some kind of <a shape="rect" href="correlation-identifier.html">Correlation Identifier</a> to correlate messages which should be processed in order by a single thread - so that things which don't correlate together can be processed concurrently.</p>
-
-<p>For example the following code shows how to create a message group using an XPath expression taking an invoice's product code as the <a shape="rect" href="correlation-identifier.html">Correlation Identifier</a></p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
-from(&quot;activemq:a&quot;).setHeader(&quot;JMSXGroupID&quot;, xpath(&quot;/invoice/productCode&quot;)).to(&quot;activemq:b&quot;);
+<h2 id="BookInOnePage-ParallelProcessingandOrdering">Parallel Processing and Ordering</h2><p>It is a common requirement to want to use parallel processing of messages for throughput and load balancing, while at the same time process certain kinds of messages in order.</p><h3 id="BookInOnePage-Howtoachieveparallelprocessing">How to achieve parallel processing</h3><p>You can send messages to a number of Camel <a shape="rect" href="components.html">Components</a> to achieve parallel processing and load balancing such as</p><ul><li><a shape="rect" href="seda.html">SEDA</a> for in-JVM load balancing across a thread pool</li><li><a shape="rect" href="activemq.html">ActiveMQ</a> or <a shape="rect" href="jms.html">JMS</a> for distributed load balancing and parallel processing</li><li><a shape="rect" href="jpa.html">JPA</a> for using the database as a poor mans message broker</li></ul><p>When processing messages concurrently, you should consider ordering and concurrency issues. These are des
 cribed below</p><h4 id="BookInOnePage-Concurrencyissues">Concurrency issues</h4><p>Note that there is no concurrency or locking issue when using <a shape="rect" href="activemq.html">ActiveMQ</a>, <a shape="rect" href="jms.html">JMS</a> or <a shape="rect" href="seda.html">SEDA</a> by design; they are designed for highly concurrent use. However there are possible concurrency issues in the <a shape="rect" href="processor.html">Processor</a> of the messages i.e. what the processor does with the message?</p><p>For example if a processor of a message transfers money from one account to another account; you probably want to use a database with pessimistic locking to ensure that operation takes place atomically.</p><h4 id="BookInOnePage-Orderingissues">Ordering issues</h4><p>As soon as you send multiple messages to different threads or processes you will end up with an unknown ordering across the entire message stream as each thread is going to process messages concurrently.</p><p>For many 
 use cases the order of messages is not too important. However for some applications this can be crucial. e.g. if a customer submits a purchase order version 1, then amends it and sends version 2; you don't want to process the first version last (so that you loose the update). Your <a shape="rect" href="processor.html">Processor</a> might be clever enough to ignore old messages. If not you need to preserve order.</p><h3 id="BookInOnePage-Recommendations">Recommendations</h3><p>This topic is large and diverse with lots of different requirements; but from a high level here are our recommendations on parallel processing, ordering and concurrency</p><ul><li>for distributed locking, use a database by default, they are very good at it <img class="emoticon emoticon-smile" src="https://cwiki.apache.org/confluence/s/en_GB-1988229788/4109/76e0dbb30bc8580e459c201f3535d84f9283a9ac.1/_/images/icons/emoticons/smile.png" data-emoticon-name="smile" alt="(smile)"></li><li>to preserve ordering across 
 a JMS queue consider using <a shape="rect" class="external-link" href="http://activemq.apache.org/exclusive-consumer.html">Exclusive Consumers</a> in the <a shape="rect" href="activemq.html">ActiveMQ</a> component</li><li>even better are <a shape="rect" class="external-link" href="http://activemq.apache.org/message-groups.html">Message Groups</a> which allows you to preserve ordering across messages while still offering parallelisation via the <strong>JMSXGroupID</strong> header to determine what can be parallelized</li><li>if you receive messages out of order you could use the <a shape="rect" href="resequencer.html">Resequencer</a> to put them back together again</li></ul><p>A good rule of thumb to help reduce ordering problems is to make sure each single can be processed as an atomic unit in parallel (either without concurrency issues or using say, database locking); or if it can't, use a <a shape="rect" class="external-link" href="http://activemq.apache.org/message-groups.html">M
 essage Group</a> to relate the messages together which need to be processed in order by a single thread.</p><h3 id="BookInOnePage-UsingMessageGroupswithCamel">Using Message Groups with Camel</h3><p>To use a Message Group with Camel you just need to add a header to the output JMS message based on some kind of <a shape="rect" href="correlation-identifier.html">Correlation Identifier</a> to correlate messages which should be processed in order by a single thread - so that things which don't correlate together can be processed concurrently.</p><p>For example the following code shows how to create a message group using an XPath expression taking an invoice's product code as the <a shape="rect" href="correlation-identifier.html">Correlation Identifier</a></p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[from(&quot;activemq:a&quot;).setHeader(JmsConstants.JMS_X_GROUP_ID, xpath(&quot;/invoice/productCode&quot;)).to(&quot;activemq:b&quot;);
 ]]></script>
-</div></div>
-
-<p>You can of course use the <a shape="rect" href="xml-configuration.html">Xml Configuration</a> if you prefer</p>
+</div></div><p>You can of course use the <a shape="rect" href="xml-configuration.html">Xml Configuration</a> if you prefer</p>
 <h2 id="BookInOnePage-AsynchronousProcessing">Asynchronous Processing</h2>
 
 <h3 id="BookInOnePage-Overview">Overview</h3>
@@ -4185,11 +4145,11 @@ While not actual tutorials you might fin
                     </div>
     </div>
 <h2 id="BookInOnePage-Preface">Preface</h2><p>This tutorial aims to guide the reader through the stages of creating a project which uses Camel to facilitate the routing of messages from a JMS queue to a <a shape="rect" class="external-link" href="http://www.springramework.org" rel="nofollow">Spring</a> service. The route works in a synchronous fashion returning a response to the client.</p><p><style type="text/css">/*<![CDATA[*/
-div.rbtoc1398107956004 {padding: 0px;}
-div.rbtoc1398107956004 ul {list-style: disc;margin-left: 0px;}
-div.rbtoc1398107956004 li {margin-left: 0px;padding-left: 0px;}
+div.rbtoc1399022302632 {padding: 0px;}
+div.rbtoc1399022302632 ul {list-style: disc;margin-left: 0px;}
+div.rbtoc1399022302632 li {margin-left: 0px;padding-left: 0px;}
 
-/*]]>*/</style></p><div class="toc-macro rbtoc1398107956004">
+/*]]>*/</style></p><div class="toc-macro rbtoc1399022302632">
 <ul class="toc-indentation"><li><a shape="rect" href="#Tutorial-JmsRemoting-TutorialonSpringRemotingwithJMS">Tutorial on Spring Remoting with JMS</a></li><li><a shape="rect" href="#Tutorial-JmsRemoting-Preface">Preface</a></li><li><a shape="rect" href="#Tutorial-JmsRemoting-Prerequisites">Prerequisites</a></li><li><a shape="rect" href="#Tutorial-JmsRemoting-Distribution">Distribution</a></li><li><a shape="rect" href="#Tutorial-JmsRemoting-About">About</a></li><li><a shape="rect" href="#Tutorial-JmsRemoting-CreatetheCamelProject">Create the Camel Project</a>
 <ul class="toc-indentation"><li><a shape="rect" href="#Tutorial-JmsRemoting-UpdatethePOMwithDependencies">Update the POM with Dependencies</a></li></ul>
 </li><li><a shape="rect" href="#Tutorial-JmsRemoting-WritingtheServer">Writing the Server</a>
@@ -6375,11 +6335,11 @@ So we completed the last piece in the pi
 
 
 <style type="text/css">/*<![CDATA[*/
-div.rbtoc1398107956438 {padding: 0px;}
-div.rbtoc1398107956438 ul {list-style: disc;margin-left: 0px;}
-div.rbtoc1398107956438 li {margin-left: 0px;padding-left: 0px;}
+div.rbtoc1399022303699 {padding: 0px;}
+div.rbtoc1399022303699 ul {list-style: disc;margin-left: 0px;}
+div.rbtoc1399022303699 li {margin-left: 0px;padding-left: 0px;}
 
-/*]]>*/</style><div class="toc-macro rbtoc1398107956438">
+/*]]>*/</style><div class="toc-macro rbtoc1399022303699">
 <ul class="toc-indentation"><li><a shape="rect" href="#Tutorial-AXIS-Camel-TutorialusingAxis1.4withApacheCamel">Tutorial using Axis 1.4 with Apache Camel</a>
 <ul class="toc-indentation"><li><a shape="rect" href="#Tutorial-AXIS-Camel-Prerequisites">Prerequisites</a></li><li><a shape="rect" href="#Tutorial-AXIS-Camel-Distribution">Distribution</a></li><li><a shape="rect" href="#Tutorial-AXIS-Camel-Introduction">Introduction</a></li><li><a shape="rect" href="#Tutorial-AXIS-Camel-SettinguptheprojecttorunAxis">Setting up the project to run Axis</a>
 <ul class="toc-indentation"><li><a shape="rect" href="#Tutorial-AXIS-Camel-Maven2">Maven 2</a></li><li><a shape="rect" href="#Tutorial-AXIS-Camel-wsdl">wsdl</a></li><li><a shape="rect" href="#Tutorial-AXIS-Camel-ConfiguringAxis">Configuring Axis</a></li><li><a shape="rect" href="#Tutorial-AXIS-Camel-RunningtheExample">Running the Example</a></li></ul>
@@ -15187,51 +15147,22 @@ from(&quot;direct:start&quot;)
 </div></div><h4 id="BookInOnePage-Knowingifwasfilteredornot">Knowing if <a shape="rect" href="exchange.html">Exchange</a> was filtered or not</h4><p><strong>Available as of Camel 2.5</strong></p><p>The <a shape="rect" href="message-filter.html">Message Filter</a> EIP will add a property on the <a shape="rect" href="exchange.html">Exchange</a> that states if it was filtered or not.</p><p>The property has the key <code>Exchange.FILTER_MATCHED</code>, which has the String value of <code>CamelFilterMatched</code>. Its value is a boolean indicating <code>true</code> or <code>false</code>. If the value is <code>true</code> then the <a shape="rect" href="exchange.html">Exchange</a> was routed in the filter block. This property will be visible within the <a shape="rect" href="message-filter.html">Message Filter</a> block who's <a shape="rect" href="predicate.html">Predicate</a> matches (value set to <code>true</code>), and to the steps immediately following the <a shape="rect" href="message
 -filter.html">Message Filter</a> with the value set based on the results of the last <a shape="rect" href="message-filter.html">Message Filter</a> <a shape="rect" href="predicate.html">Predicate</a> evaluated.</p><p></p><h4 id="BookInOnePage-UsingThisPattern.15">Using This Pattern</h4>
 
 <p>If you would like to use this EIP Pattern then please read the <a shape="rect" href="getting-started.html">Getting Started</a>, you may also find the <a shape="rect" href="architecture.html">Architecture</a> useful particularly the description of <a shape="rect" href="endpoint.html">Endpoint</a> and <a shape="rect" href="uris.html">URIs</a>. Then you could try out some of the <a shape="rect" href="examples.html">Examples</a> first before trying this pattern out.</p>
-<h2 id="BookInOnePage-DynamicRouter">Dynamic Router</h2>
-
-<p>The <a shape="rect" class="external-link" href="http://www.enterpriseintegrationpatterns.com/DynamicRouter.html" rel="nofollow">Dynamic Router</a> from the <a shape="rect" href="enterprise-integration-patterns.html">EIP patterns</a> allows you to route messages while avoiding the dependency of the router on all possible destinations while maintaining its efficiency.</p>
-
-<p><img class="confluence-embedded-image confluence-external-resource" src="http://www.enterpriseintegrationpatterns.com/img/DynamicRouter.gif" data-image-src="http://www.enterpriseintegrationpatterns.com/img/DynamicRouter.gif"></p>
-
-<p>In <strong>Camel 2.5</strong> we introduced a <code>dynamicRouter</code> in the DSL which is like a dynamic <a shape="rect" href="routing-slip.html">Routing Slip</a> which evaluates the slip <em>on-the-fly</em>. </p>
-
-    <div class="aui-message problem shadowed information-macro">
+<h2 id="BookInOnePage-DynamicRouter">Dynamic Router</h2><p>The <a shape="rect" class="external-link" href="http://www.enterpriseintegrationpatterns.com/DynamicRouter.html" rel="nofollow">Dynamic Router</a> from the <a shape="rect" href="enterprise-integration-patterns.html">EIP patterns</a> allows you to route messages while avoiding the dependency of the router on all possible destinations while maintaining its efficiency.</p><p><img class="confluence-embedded-image confluence-external-resource" src="http://www.enterpriseintegrationpatterns.com/img/DynamicRouter.gif" data-image-src="http://www.enterpriseintegrationpatterns.com/img/DynamicRouter.gif"></p><p>In <strong>Camel 2.5</strong> we introduced a <code>dynamicRouter</code> in the DSL which is like a dynamic <a shape="rect" href="routing-slip.html">Routing Slip</a> which evaluates the slip <em>on-the-fly</em>.</p>    <div class="aui-message problem shadowed information-macro">
                     <p class="title">Beware</p>
                             <span class="aui-icon icon-problem">Icon</span>
                 <div class="message-content">
-                            
-<p>You must ensure the expression used for the <code>dynamicRouter</code> such as a bean, will return <code>null</code> to indicate the end. Otherwise the <code>dynamicRouter</code> will keep repeating endlessly.</p>
+                            <p>You must ensure the expression used for the <code>dynamicRouter</code> such as a bean, will return <code>null</code> to indicate the end. Otherwise the <code>dynamicRouter</code> will keep repeating endlessly.</p>
                     </div>
     </div>
-
-
-
-<h3 id="BookInOnePage-Options.10">Options</h3>
-
-<div class="confluenceTableSmall">
-<table class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" class="confluenceTh"><p> Name </p></th><th colspan="1" rowspan="1" class="confluenceTh"><p> Default Value </p></th><th colspan="1" rowspan="1" class="confluenceTh"><p> Description </p></th></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>uriDelimiter</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>,</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> Delimiter used if the <a shape="rect" href="expression.html" title="Expression">Expression</a> returned multiple endpoints. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>ignoreInvalidEndpoints</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> If an endpoint uri could not be resolved, should it be ignored. Otherwise Camel will thrown an exception stating the endpoint uri is not 
 valid. </p></td></tr></tbody></table>
-</div>
-
-
-<h3 id="BookInOnePage-DynamicRouterinCamel2.5onwards">Dynamic Router in Camel 2.5 onwards</h3>
-
-<p>From Camel 2.5 the <a shape="rect" href="dynamic-router.html">Dynamic Router</a> will set a property (Exchange.SLIP_ENDPOINT) on the <a shape="rect" href="exchange.html">Exchange</a> which contains the current endpoint as it advanced though the slip. This allows you to know how far we have processed in the slip. (It's a slip because the <a shape="rect" href="dynamic-router.html">Dynamic Router</a> implementation is based on top of <a shape="rect" href="routing-slip.html">Routing Slip</a>).</p>
-
-<h4 id="BookInOnePage-JavaDSL.2">Java DSL</h4>
-
-<p>In Java DSL you can use the <code>dynamicRouter</code> as shown below:</p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<h3 id="BookInOnePage-Options.10">Options</h3><div class="confluenceTableSmall">
+<table class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" class="confluenceTh"><p> Name </p></th><th colspan="1" rowspan="1" class="confluenceTh"><p> Default Value </p></th><th colspan="1" rowspan="1" class="confluenceTh"><p> Description </p></th></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>uriDelimiter</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>,</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> Delimiter used if the <a shape="rect" href="expression.html" title="Expression">Expression</a> returned multiple endpoints. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>ignoreInvalidEndpoints</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> If an endpoint uri could not be resolved, should it be ignored. Otherwise Camel will thrown an exception stating the endpoint uri is not 
 valid. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>cacheSize</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>1000</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.13.1/2.12.4:</strong> Allows to configure the cache size for the <code>ProducerCache</code> which caches producers for reuse in the routing slip. Will by default use the default cache size which is 1000. Setting the value to -1 allows to turn off the cache all together. </p></td></tr></tbody></table>
+</div><h3 id="BookInOnePage-DynamicRouterinCamel2.5onwards">Dynamic Router in Camel 2.5 onwards</h3><p>From Camel 2.5 the <a shape="rect" href="dynamic-router.html">Dynamic Router</a> will set a property (Exchange.SLIP_ENDPOINT) on the <a shape="rect" href="exchange.html">Exchange</a> which contains the current endpoint as it advanced though the slip. This allows you to know how far we have processed in the slip. (It's a slip because the <a shape="rect" href="dynamic-router.html">Dynamic Router</a> implementation is based on top of <a shape="rect" href="routing-slip.html">Routing Slip</a>).</p><h4 id="BookInOnePage-JavaDSL.2">Java DSL</h4><p>In Java DSL you can use the <code>dynamicRouter</code> as shown below:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
 from(&quot;direct:start&quot;)
     // use a bean as the dynamic router
     .dynamicRouter(method(DynamicRouterTest.class, &quot;slip&quot;));
 ]]></script>
-</div></div>
-
-<p>Which will leverage a <a shape="rect" href="bean.html">Bean</a> to compute the slip <em>on-the-fly</em>, which could be implemented as follows:</p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+</div></div><p>Which will leverage a <a shape="rect" href="bean.html">Bean</a> to compute the slip <em>on-the-fly</em>, which could be implemented as follows:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
 /**
  * Use this method to compute dynamic where we should route next.
@@ -15257,10 +15188,7 @@ public String slip(String body) {
     return null;
 }
 ]]></script>
-</div></div>
-
-<p>Mind that this example is only for show and tell. The current implementation is not thread safe. You would have to store the state on the <a shape="rect" href="exchange.html">Exchange</a>, to ensure thread safety, as shown below: </p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+</div></div><p>Mind that this example is only for show and tell. The current implementation is not thread safe. You would have to store the state on the <a shape="rect" href="exchange.html">Exchange</a>, to ensure thread safety, as shown below:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
 /**
  * Use this method to compute dynamic where we should route next.
@@ -15297,24 +15225,14 @@ public String slip(String body, @Propert
     return null;
 }
 ]]></script>
-</div></div>
-
-<p>You could also store state as message headers, but they are not guaranteed to be preserved during routing, where as properties on the <a shape="rect" href="exchange.html">Exchange</a> are. Although there was a bug in the method call expression, see the warning below.</p>
-
-    <div class="aui-message problem shadowed information-macro">
+</div></div><p>You could also store state as message headers, but they are not guaranteed to be preserved during routing, where as properties on the <a shape="rect" href="exchange.html">Exchange</a> are. Although there was a bug in the method call expression, see the warning below.</p>    <div class="aui-message problem shadowed information-macro">
                     <p class="title">Using beans to store state</p>
                             <span class="aui-icon icon-problem">Icon</span>
                 <div class="message-content">
-                            
-<p>Mind that in Camel 2.9.2 or older, when using a <a shape="rect" href="bean.html">Bean</a> the state is not propagated, so you will have to use a <a shape="rect" href="processor.html">Processor</a> instead. This is fixed in Camel 2.9.3 onwards.</p>
+                            <p>Mind that in Camel 2.9.2 or older, when using a <a shape="rect" href="bean.html">Bean</a> the state is not propagated, so you will have to use a <a shape="rect" href="processor.html">Processor</a> instead. This is fixed in Camel 2.9.3 onwards.</p>
                     </div>
     </div>
-
-
-<h4 id="BookInOnePage-SpringXML.1">Spring XML</h4>
-<p>The same example in Spring XML would be:</p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<h4 id="BookInOnePage-SpringXML.1">Spring XML</h4><p>The same example in Spring XML would be:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[
 &lt;bean id=&quot;mySlip&quot; class=&quot;org.apache.camel.processor.DynamicRouterTest&quot;/&gt;
 
@@ -15335,14 +15253,8 @@ public String slip(String body, @Propert
 
 &lt;/camelContext&gt;
 ]]></script>
-</div></div>
-
-<h4 id="BookInOnePage-@DynamicRouterannotation">@DynamicRouter annotation</h4>
-
-<p>You can also use the <code>@DynamicRouter</code> annotation, for example the Camel 2.4 example below could be written as follows. The <code>route</code> method would then be invoked repeatedly as the message is processed dynamically. The idea is to return the next endpoint uri where to go. Return <code>null</code> to indicate the end. You can return multiple endpoints if you like, just as the <a shape="rect" href="routing-slip.html">Routing Slip</a>, where each endpoint is separated by a delimiter.</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
-public class MyDynamicRouter {
+</div></div><h4 id="BookInOnePage-@DynamicRouterannotation">@DynamicRouter annotation</h4><p>You can also use the <code>@DynamicRouter</code> annotation, for example the Camel 2.4 example below could be written as follows. The <code>route</code> method would then be invoked repeatedly as the message is processed dynamically. The idea is to return the next endpoint uri where to go. Return <code>null</code> to indicate the end. You can return multiple endpoints if you like, just as the <a shape="rect" href="routing-slip.html">Routing Slip</a>, where each endpoint is separated by a delimiter.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[public class MyDynamicRouter {
 
     @Consume(uri = &quot;activemq:foo&quot;)
     @DynamicRouter
@@ -15352,14 +15264,8 @@ public class MyDynamicRouter {
     }
 }
 ]]></script>
-</div></div>
-
-<h3 id="BookInOnePage-DynamicRouterinCamel2.4orolder">Dynamic Router in Camel 2.4 or older</h3>
-<p>The simplest way to implement this is to use the <a shape="rect" href="recipientlist-annotation.html">RecipientList Annotation</a> on a Bean method to determine where to route the message.</p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
-public class MyDynamicRouter {
+</div></div><h3 id="BookInOnePage-DynamicRouterinCamel2.4orolder">Dynamic Router in Camel 2.4 or older</h3><p>The simplest way to implement this is to use the <a shape="rect" href="recipientlist-annotation.html">RecipientList Annotation</a> on a Bean method to determine where to route the message.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[public class MyDynamicRouter {
 
     @Consume(uri = &quot;activemq:foo&quot;)
     @RecipientList
@@ -15369,20 +15275,11 @@ public class MyDynamicRouter {
     }
 }
 ]]></script>
-</div></div>
-
-<p>In the above we can use the <a shape="rect" href="parameter-binding-annotations.html">Parameter Binding Annotations</a> to bind different parts of the <a shape="rect" href="message.html">Message</a> to method parameters or use an <a shape="rect" href="expression.html">Expression</a> such as using <a shape="rect" href="xpath.html">XPath</a> or <a shape="rect" href="xquery.html">XQuery</a>.</p>
-
-<p>The method can be invoked in a number of ways as described in the <a shape="rect" href="bean-integration.html">Bean Integration</a> such as</p>
-
-<ul><li><a shape="rect" href="pojo-producing.html">POJO Producing</a></li><li><a shape="rect" href="spring-remoting.html">Spring Remoting</a></li><li><a shape="rect" href="bean.html">Bean</a> component</li></ul>
-
-
-<h4 id="BookInOnePage-UsingThisPattern.16">Using This Pattern</h4>
+</div></div><p>In the above we can use the <a shape="rect" href="parameter-binding-annotations.html">Parameter Binding Annotations</a> to bind different parts of the <a shape="rect" href="message.html">Message</a> to method parameters or use an <a shape="rect" href="expression.html">Expression</a> such as using <a shape="rect" href="xpath.html">XPath</a> or <a shape="rect" href="xquery.html">XQuery</a>.</p><p>The method can be invoked in a number of ways as described in the <a shape="rect" href="bean-integration.html">Bean Integration</a> such as</p><ul><li><a shape="rect" href="pojo-producing.html">POJO Producing</a></li><li><a shape="rect" href="spring-remoting.html">Spring Remoting</a></li><li><a shape="rect" href="bean.html">Bean</a> component</li></ul><p></p><h4 id="BookInOnePage-UsingThisPattern.16">Using This Pattern</h4>
 
 <p>If you would like to use this EIP Pattern then please read the <a shape="rect" href="getting-started.html">Getting Started</a>, you may also find the <a shape="rect" href="architecture.html">Architecture</a> useful particularly the description of <a shape="rect" href="endpoint.html">Endpoint</a> and <a shape="rect" href="uris.html">URIs</a>. Then you could try out some of the <a shape="rect" href="examples.html">Examples</a> first before trying this pattern out.</p>
 <h3 id="BookInOnePage-RecipientList">Recipient List</h3><p>The <a shape="rect" class="external-link" href="http://www.enterpriseintegrationpatterns.com/RecipientList.html" rel="nofollow">Recipient List</a> from the <a shape="rect" href="enterprise-integration-patterns.html">EIP patterns</a> allows you to route messages to a number of dynamically specified recipients.</p><p><img class="confluence-embedded-image confluence-external-resource" src="http://www.enterpriseintegrationpatterns.com/img/RecipientList.gif" data-image-src="http://www.enterpriseintegrationpatterns.com/img/RecipientList.gif"></p><p>The recipients will receive a copy of the <strong>same</strong> <a shape="rect" href="exchange.html">Exchange</a>, and Camel will execute them sequentially.</p><h3 id="BookInOnePage-Options.11">Options</h3><div class="confluenceTableSmall">
-<table class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" class="confluenceTh"><p> Name </p></th><th colspan="1" rowspan="1" class="confluenceTh"><p> Default Value </p></th><th colspan="1" rowspan="1" class="confluenceTh"><p> Description </p></th></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>delimiter</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>,</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> Delimiter used if the <a shape="rect" href="expression.html" title="Expression">Expression</a> returned multiple endpoints. <strong>Camel 2.13</strong> can be disabled using "false" </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>strategyRef</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> An <a shape="rect" class="external-link" href="http://camel.apache.org/maven/current/camel-core/apidocs/org
 /apache/camel/processor/aggregate/AggregationStrategy.html">AggregationStrategy</a> that will assemble the replies from recipients into a single outgoing message from the <a shape="rect" href="recipient-list.html" title="Recipient List">Recipient List</a>. By default Camel will use the last reply as the outgoing message. From <strong>Camel 2.12</strong> onwards you can also use a POJO as the <code>AggregationStrategy</code>, see the <a shape="rect" href="aggregator2.html" title="Aggregator2">Aggregate</a> page for more details. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>strategyMethodName</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.12:</strong> This option can be used to explicit declare the method name to use, when using POJOs as the <code>AggregationStrategy</code>. See the <a shape="rect" href="aggregator2.html" title="Aggregator2">Aggregat
 e</a> page for more details. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>strategyMethodAllowNull</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.12:</strong> If this option is <code>false</code> then the aggregate method is not used if there was no data to enrich. If this option is <code>true</code> then <code>null</code> values is used as the <code>oldExchange</code> (when no data to enrich), when using POJOs as the <code>AggregationStrategy</code>. See the <a shape="rect" href="aggregator2.html" title="Aggregator2">Aggregate</a> page for more details. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>parallelProcessing</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.2:</strong> If enabled, 
 messages are sent to the recipients concurrently. Note that the calling thread will still wait until all messages have been fully processed before it continues; it's the sending and processing of replies from recipients which happens in parallel. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>executorServiceRef</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.2:</strong> A custom <a shape="rect" href="threading-model.html" title="Threading Model">Thread Pool</a> to use for parallel processing. Note that enabling this option implies parallel processing, so you need not enable that option as well. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>stopOnException</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.2:
 </strong> Whether to immediately stop processing when an exception occurs. If disabled, Camel will send the message to all recipients regardless of any individual failures. You can process exceptions in an <a shape="rect" class="external-link" href="http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/processor/aggregate/AggregationStrategy.html">AggregationStrategy</a> implementation, which supports full control of error handling. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>ignoreInvalidEndpoints</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.3:</strong> Whether to ignore an endpoint URI that could not be resolved. If disabled, Camel will throw an exception identifying the invalid endpoint URI. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>streaming</code> </p></td><td colspan="1" 
 rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.5:</strong> If enabled, Camel will process replies out-of-order - that is, in the order received in reply from each recipient. If disabled, Camel will process replies in the same order as specified by the <a shape="rect" href="expression.html" title="Expression">Expression</a>. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>timeout</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.5:</strong> Specifies a processing timeout milliseconds. If the <a shape="rect" href="recipient-list.html" title="Recipient List">Recipient List</a> hasn't been able to send and process all replies within this timeframe, then the timeout triggers and the <a shape="rect" href="recipient-list.html" title="Recipient List">Recipient List</a> breaks 
 out, with message flow continuing to the next element. Note that if you provide a <a shape="rect" class="external-link" href="http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/processor/aggregate/TimeoutAwareAggregationStrategy.html">TimeoutAwareAggregationStrategy</a>, its <code>timeout</code> method is invoked before breaking out. <strong>Beware:</strong> If the timeout is reached with running tasks still remaining, certain tasks for which it is difficult for Camel to shut down in a graceful manner may continue to run.  So use this option with a bit of care.  We may be able to improve this functionality in future Camel releases. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>onPrepareRef</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.8:</strong> A custom <a shape="rect" href="processor.html" title="Processor">Processor</a> t
 o prepare the copy of the <a shape="rect" href="exchange.html" title="Exchange">Exchange</a> each recipient will receive. This allows you to perform arbitrary transformations, such as deep-cloning the message payload (or any other custom logic). </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>shareUnitOfWork</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.8:</strong> Whether the unit of work should be shared. See <a shape="rect" href="splitter.html#Splitter-Sharingunitofwork">the same option on Splitter</a> for more details. </p></td></tr></tbody></table>
+<table class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" class="confluenceTh"><p> Name </p></th><th colspan="1" rowspan="1" class="confluenceTh"><p> Default Value </p></th><th colspan="1" rowspan="1" class="confluenceTh"><p> Description </p></th></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>delimiter</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>,</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> Delimiter used if the <a shape="rect" href="expression.html" title="Expression">Expression</a> returned multiple endpoints. <strong>Camel 2.13</strong> can be disabled using "false" </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>strategyRef</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> An <a shape="rect" class="external-link" href="http://camel.apache.org/maven/current/camel-core/apidocs/org
 /apache/camel/processor/aggregate/AggregationStrategy.html">AggregationStrategy</a> that will assemble the replies from recipients into a single outgoing message from the <a shape="rect" href="recipient-list.html" title="Recipient List">Recipient List</a>. By default Camel will use the last reply as the outgoing message. From <strong>Camel 2.12</strong> onwards you can also use a POJO as the <code>AggregationStrategy</code>, see the <a shape="rect" href="aggregator2.html" title="Aggregator2">Aggregate</a> page for more details. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>strategyMethodName</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.12:</strong> This option can be used to explicit declare the method name to use, when using POJOs as the <code>AggregationStrategy</code>. See the <a shape="rect" href="aggregator2.html" title="Aggregator2">Aggregat
 e</a> page for more details. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>strategyMethodAllowNull</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.12:</strong> If this option is <code>false</code> then the aggregate method is not used if there was no data to enrich. If this option is <code>true</code> then <code>null</code> values is used as the <code>oldExchange</code> (when no data to enrich), when using POJOs as the <code>AggregationStrategy</code>. See the <a shape="rect" href="aggregator2.html" title="Aggregator2">Aggregate</a> page for more details. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>parallelProcessing</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.2:</strong> If enabled, 
 messages are sent to the recipients concurrently. Note that the calling thread will still wait until all messages have been fully processed before it continues; it's the sending and processing of replies from recipients which happens in parallel. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>executorServiceRef</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.2:</strong> A custom <a shape="rect" href="threading-model.html" title="Threading Model">Thread Pool</a> to use for parallel processing. Note that enabling this option implies parallel processing, so you need not enable that option as well. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>stopOnException</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.2:
 </strong> Whether to immediately stop processing when an exception occurs. If disabled, Camel will send the message to all recipients regardless of any individual failures. You can process exceptions in an <a shape="rect" class="external-link" href="http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/processor/aggregate/AggregationStrategy.html">AggregationStrategy</a> implementation, which supports full control of error handling. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>ignoreInvalidEndpoints</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.3:</strong> Whether to ignore an endpoint URI that could not be resolved. If disabled, Camel will throw an exception identifying the invalid endpoint URI. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>streaming</code> </p></td><td colspan="1" 
 rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.5:</strong> If enabled, Camel will process replies out-of-order - that is, in the order received in reply from each recipient. If disabled, Camel will process replies in the same order as specified by the <a shape="rect" href="expression.html" title="Expression">Expression</a>. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>timeout</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.5:</strong> Specifies a processing timeout milliseconds. If the <a shape="rect" href="recipient-list.html" title="Recipient List">Recipient List</a> hasn't been able to send and process all replies within this timeframe, then the timeout triggers and the <a shape="rect" href="recipient-list.html" title="Recipient List">Recipient List</a> breaks 
 out, with message flow continuing to the next element. Note that if you provide a <a shape="rect" class="external-link" href="http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/processor/aggregate/TimeoutAwareAggregationStrategy.html">TimeoutAwareAggregationStrategy</a>, its <code>timeout</code> method is invoked before breaking out. <strong>Beware:</strong> If the timeout is reached with running tasks still remaining, certain tasks for which it is difficult for Camel to shut down in a graceful manner may continue to run.  So use this option with a bit of care.  We may be able to improve this functionality in future Camel releases. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>onPrepareRef</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.8:</strong> A custom <a shape="rect" href="processor.html" title="Processor">Processor</a> t
 o prepare the copy of the <a shape="rect" href="exchange.html" title="Exchange">Exchange</a> each recipient will receive. This allows you to perform arbitrary transformations, such as deep-cloning the message payload (or any other custom logic). </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>shareUnitOfWork</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.8:</strong> Whether the unit of work should be shared. See <a shape="rect" href="splitter.html#Splitter-Sharingunitofwork">the same option on Splitter</a> for more details. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>cacheSize</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>1000</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.13.1/2.12.4:</strong> Allows to configure the cache size for the <c
 ode>ProducerCache</code> which caches producers for reuse in the routing slip. Will by default use the default cache size which is 1000. Setting the value to -1 allows to turn off the cache all together. </p></td></tr></tbody></table>
 </div><h4 id="BookInOnePage-StaticRecipientList">Static Recipient List</h4><p>The following example shows how to route a request from an input <strong>queue:a</strong> endpoint to a static list of destinations</p><p><strong>Using Annotations</strong><br clear="none"> You can use the <a shape="rect" href="recipientlist-annotation.html">RecipientList Annotation</a> on a POJO to create a Dynamic Recipient List. For more details see the <a shape="rect" href="bean-integration.html">Bean Integration</a>.</p><p><strong>Using the <a shape="rect" href="fluent-builders.html">Fluent Builders</a></strong></p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
 RouteBuilder builder = new RouteBuilder() {
@@ -15593,32 +15490,9 @@ from(&quot;direct:c&quot;).to(&quot;mock
 <h3 id="BookInOnePage-UsingonPreparetoexecutecustomlogicwhenpreparingmessages">Using onPrepare to execute custom logic when preparing messages</h3><p><strong>Available as of Camel 2.8</strong></p><p>See details at <a shape="rect" href="multicast.html">Multicast</a></p><p></p><h4 id="BookInOnePage-UsingThisPattern.17">Using This Pattern</h4>
 
 <p>If you would like to use this EIP Pattern then please read the <a shape="rect" href="getting-started.html">Getting Started</a>, you may also find the <a shape="rect" href="architecture.html">Architecture</a> useful particularly the description of <a shape="rect" href="endpoint.html">Endpoint</a> and <a shape="rect" href="uris.html">URIs</a>. Then you could try out some of the <a shape="rect" href="examples.html">Examples</a> first before trying this pattern out.</p>
-<h3 id="BookInOnePage-Splitter">Splitter</h3>
-
-<p>The <a shape="rect" class="external-link" href="http://www.enterpriseintegrationpatterns.com/Sequencer.html" rel="nofollow">Splitter</a> from the <a shape="rect" href="enterprise-integration-patterns.html">EIP patterns</a> allows you split a message into a number of pieces and process them individually</p>
-
-<p><img class="confluence-embedded-image confluence-external-resource" src="http://www.enterpriseintegrationpatterns.com/img/Sequencer.gif" data-image-src="http://www.enterpriseintegrationpatterns.com/img/Sequencer.gif"></p>
-
-<p>You need to specify a Splitter as <code>split()</code>. In earlier versions of Camel, you need to use <code>splitter()</code>.</p>
-
-
-<h3 id="BookInOnePage-Options.12">Options</h3>
-
-<div class="confluenceTableSmall">
+<h3 id="BookInOnePage-Splitter">Splitter</h3><p>The <a shape="rect" class="external-link" href="http://www.enterpriseintegrationpatterns.com/Sequencer.html" rel="nofollow">Splitter</a> from the <a shape="rect" href="enterprise-integration-patterns.html">EIP patterns</a> allows you split a message into a number of pieces and process them individually</p><p><img class="confluence-embedded-image confluence-external-resource" src="http://www.enterpriseintegrationpatterns.com/img/Sequencer.gif" data-image-src="http://www.enterpriseintegrationpatterns.com/img/Sequencer.gif"></p><p>You need to specify a Splitter as <code>split()</code>. In earlier versions of Camel, you need to use <code>splitter()</code>.</p><h3 id="BookInOnePage-Options.12">Options</h3><div class="confluenceTableSmall">
 <table class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" class="confluenceTh"><p> Name </p></th><th colspan="1" rowspan="1" class="confluenceTh"><p> Default Value </p></th><th colspan="1" rowspan="1" class="confluenceTh"><p> Description </p></th></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>strategyRef</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> Refers to an <a shape="rect" class="external-link" href="http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/processor/aggregate/AggregationStrategy.html">AggregationStrategy</a> to be used to assemble the replies from the sub-messages, into a single outgoing message from the <a shape="rect" href="splitter.html" title="Splitter">Splitter</a>. See the defaults described below in <em><a shape="rect" href="#BookInOnePage-WhattheSplitterreturns">What the Splitter returns</a></em>. From <strong>Camel
  2.12</strong> onwards you can also use a POJO as the <code>AggregationStrategy</code>, see the <a shape="rect" href="aggregator2.html" title="Aggregator2">Aggregate</a> page for more details. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>strategyMethodName</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.12:</strong> This option can be used to explicit declare the method name to use, when using POJOs as the <code>AggregationStrategy</code>. See the <a shape="rect" href="aggregator2.html" title="Aggregator2">Aggregate</a> page for more details. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>strategyMethodAllowNull</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.12:</strong> If this option is <code>false</c
 ode> then the aggregate method is not used for the very first splitted message. If this option is <code>true</code> then <code>null</code> values is used as the <code>oldExchange</code> (for the very first message splitted), when using POJOs as the <code>AggregationStrategy</code>. See the <a shape="rect" href="aggregator2.html" title="Aggregator2">Aggregate</a> page for more details. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>parallelProcessing</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> If enabled then processing the sub-messages occurs concurrently. Note the caller thread will still wait until all sub-messages has been fully processed, before it continues. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>executorServiceRef</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspa
 n="1" rowspan="1" class="confluenceTd"><p> Refers to a custom <a shape="rect" href="threading-model.html" title="Threading Model">Thread Pool</a> to be used for parallel processing. Notice if you set this option, then parallel processing is automatically implied, and you do not have to enable that option as well. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>stopOnException</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.2:</strong> Whether or not to stop continue processing immediately when an exception occurred. If disable, then Camel continue splitting and process the sub-messages regardless if one of them failed. You can deal with exceptions in the <a shape="rect" class="external-link" href="http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/processor/aggregate/AggregationStrategy.html">AggregationStrategy</a>
  class where you have full control how to handle that. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>streaming</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> If enabled then Camel will split in a streaming fashion, which means it will split the input message in chunks. This reduces the memory overhead. For example if you split big messages its recommended to enable streaming. If streaming is enabled then the sub-message replies will be aggregated out-of-order, eg in the order they come back. If disabled, Camel will process sub-message replies in the same order as they where splitted. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>timeout</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.5:</strong> Sets a total timeout sp
 ecified in millis. If the <a shape="rect" href="recipient-list.html" title="Recipient List">Recipient List</a> hasn't been able to split and process all replies within the given timeframe, then the timeout triggers and the <a shape="rect" href="splitter.html" title="Splitter">Splitter</a> breaks out and continues. Notice if you provide a <a shape="rect" class="external-link" href="http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/processor/aggregate/TimeoutAwareAggregationStrategy.html">TimeoutAwareAggregationStrategy</a> then the <code>timeout</code> method is invoked before breaking out. If the timeout is reached with running tasks still remaining, certain tasks for which it is difficult for Camel to shut down in a graceful manner may continue to run.  So use this option with a bit of care.  We may be able to improve this functionality in future Camel releases. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>onPrepareRef</code> 
 </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>&#160;</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.8:</strong> Refers to a custom <a shape="rect" href="processor.html" title="Processor">Processor</a> to prepare the sub-message of the <a shape="rect" href="exchange.html" title="Exchange">Exchange</a>, before its processed. This allows you to do any custom logic, such as deep-cloning the message payload if that's needed etc. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>shareUnitOfWork</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>false</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.8:</strong> Whether the unit of work should be shared. See further below for more details. </p></td></tr></tbody></table>
-</div>
-
-<h3 id="BookInOnePage-Exchangeproperties">Exchange properties</h3>
-<p>The following properties are set on each Exchange that are split:</p>
-<div class="table-wrap"><table class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" class="confluenceTh"><p> property </p></th><th colspan="1" rowspan="1" class="confluenceTh"><p> type </p></th><th colspan="1" rowspan="1" class="confluenceTh"><p> description </p></th></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>CamelSplitIndex</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> int </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> A split counter that increases for each Exchange being split. The counter starts from 0. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>CamelSplitSize</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> int </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> The total number of Exchanges that was splitted. This header is not applied for stream based splitting. From <strong>Camel 2.9</strong> onwards this header is also set in stream based 
 splitting, but only on the completed Exchange. </p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p> <code>CamelSplitComplete</code> </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> boolean </p></td><td colspan="1" rowspan="1" class="confluenceTd"><p> <strong>Camel 2.4:</strong> Whether or not this Exchange is the last. </p></td></tr></tbody></table></div>
-
-
-<h3 id="BookInOnePage-Examples.7">Examples</h3>
-
-<p>The following example shows how to take a request from the <strong>queue:a</strong> endpoint the split it into pieces using an <a shape="rect" href="expression.html">Expression</a>, then forward each piece to <strong>queue:b</strong></p>
-
-<p><strong>Using the <a shape="rect" href="fluent-builders.html">Fluent Builders</a></strong></p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+</div><h3 id="BookInOnePage-Exchangeproperties">Exchange properties</h3><p>The following properties are set on each Exchange that are split:</p><div class="table-wrap"><table class="confluenceTable"><tbody><tr><th colspan="1" rowspan="1" class="confluenceTh"><p>property</p></th><th colspan="1" rowspan="1" class="confluenceTh"><p>type</p></th><th colspan="1" rowspan="1" class="confluenceTh"><p>description</p></th></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p><code>CamelSplitIndex</code></p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>int</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>A split counter that increases for each Exchange being split. The counter starts from 0.</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p><code>CamelSplitSize</code></p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>int</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>The total number of Exchanges that was splitted. This hea
 der is not applied for stream based splitting. From <strong>Camel 2.9</strong> onwards this header is also set in stream based splitting, but only on the completed Exchange.</p></td></tr><tr><td colspan="1" rowspan="1" class="confluenceTd"><p><code>CamelSplitComplete</code></p></td><td colspan="1" rowspan="1" class="confluenceTd"><p>boolean</p></td><td colspan="1" rowspan="1" class="confluenceTd"><p><strong>Camel 2.4:</strong> Whether or not this Exchange is the last.</p></td></tr></tbody></table></div><h3 id="BookInOnePage-Examples.7">Examples</h3><p>The following example shows how to take a request from the <strong>queue:a</strong> endpoint the split it into pieces using an <a shape="rect" href="expression.html">Expression</a>, then forward each piece to <strong>queue:b</strong></p><p><strong>Using the <a shape="rect" href="fluent-builders.html">Fluent Builders</a></strong></p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
 RouteBuilder builder = new RouteBuilder() {
     public void configure() {
@@ -15630,18 +15504,10 @@ RouteBuilder builder = new RouteBuilder(
     }
 };
 ]]></script>
-</div></div>
-
-<p>The splitter can use any <a shape="rect" href="expression.html">Expression</a> language so you could use any of the <a shape="rect" href="languages-supported.html">Languages Supported</a> such as <a shape="rect" href="xpath.html">XPath</a>, <a shape="rect" href="xquery.html">XQuery</a>, <a shape="rect" href="sql.html">SQL</a> or one of the <a shape="rect" href="scripting-languages.html">Scripting Languages</a> to perform the split. e.g.</p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
-from(&quot;activemq:my.queue&quot;).split(xpath(&quot;//foo/bar&quot;)).convertBodyTo(String.class).to(&quot;file://some/directory&quot;)
+</div></div><p>The splitter can use any <a shape="rect" href="expression.html">Expression</a> language so you could use any of the <a shape="rect" href="languages-supported.html">Languages Supported</a> such as <a shape="rect" href="xpath.html">XPath</a>, <a shape="rect" href="xquery.html">XQuery</a>, <a shape="rect" href="sql.html">SQL</a> or one of the <a shape="rect" href="scripting-languages.html">Scripting Languages</a> to perform the split. e.g.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[from(&quot;activemq:my.queue&quot;).split(xpath(&quot;//foo/bar&quot;)).convertBodyTo(String.class).to(&quot;file://some/directory&quot;)
 ]]></script>
-</div></div>
-
-<p><strong>Using the <a shape="rect" href="spring-xml-extensions.html">Spring XML Extensions</a></strong></p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+</div></div><p><strong>Using the <a shape="rect" href="spring-xml-extensions.html">Spring XML Extensions</a></strong></p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[
 &lt;camelContext errorHandlerRef=&quot;errorHandler&quot; xmlns=&quot;http://camel.apache.org/schema/spring&quot;&gt;
     &lt;route&gt;
@@ -15653,15 +15519,7 @@ from(&quot;activemq:my.queue&quot;).spli
     &lt;/route&gt;
 &lt;/camelContext&gt;
 ]]></script>
-</div></div>
-
-<p>For further examples of this pattern in use you could look at one of the <a shape="rect" class="external-link" href="http://svn.apache.org/viewvc/camel/trunk/camel-core/src/test/java/org/apache/camel/processor/SplitterTest.java?view=markup">junit test case</a></p>
-
-<h3 id="BookInOnePage-UsingTokenizerfrom*">Using Tokenizer from <a shape="rect" href="spring-xml-extensions.html">Spring XML Extensions</a>*</h3>
-
-<p>You can use the tokenizer expression in the Spring DSL to split bodies or headers using a token. This is a common use-case, so we provided a special <strong>tokenizer</strong> tag for this.<br clear="none">
-In the sample below we split the body using a @ as separator. You can of course use comma or space or even a regex pattern, also set regex=true.</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+</div></div><p>For further examples of this pattern in use you could look at one of the <a shape="rect" class="external-link" href="http://svn.apache.org/viewvc/camel/trunk/camel-core/src/test/java/org/apache/camel/processor/SplitterTest.java?view=markup">junit test case</a></p><h3 id="BookInOnePage-UsingTokenizerfrom*">Using Tokenizer from <a shape="rect" href="spring-xml-extensions.html">Spring XML Extensions</a>*</h3><p>You can use the tokenizer expression in the Spring DSL to split bodies or headers using a token. This is a common use-case, so we provided a special <strong>tokenizer</strong> tag for this.<br clear="none"> In the sample below we split the body using a @ as separator. You can of course use comma or space or even a regex pattern, also set regex=true.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
 <script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[
 &lt;camelContext xmlns=&quot;http://camel.apache.org/schema/spring&quot;&gt;
     &lt;route&gt;
@@ -15673,94 +15531,45 @@ In the sample below we split the body us
     &lt;/route&gt;
 &lt;/camelContext&gt;
 ]]></script>
-</div></div>
-
-<p>Splitting the body in Spring XML is a bit harder as you need to use the <a shape="rect" href="simple.html">Simple</a> language to dictate this</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[
-&lt;split&gt;
+</div></div><p>Splitting the body in Spring XML is a bit harder as you need to use the <a shape="rect" href="simple.html">Simple</a> language to dictate this</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[&lt;split&gt;
    &lt;simple&gt;${body}&lt;/simple&gt;
    &lt;to uri=&quot;mock:result&quot;/&gt;
 &lt;/split&gt;
 ]]></script>
-</div></div>
-
-<h3 id="BookInOnePage-WhattheSplitterreturns">What the Splitter returns</h3>
-<p><strong>Camel 2.2 or older:</strong><br clear="none">
-The <a shape="rect" href="splitter.html">Splitter</a> will by default return the <strong>last</strong> splitted message.</p>
-
-<p><strong>Camel 2.3 and newer</strong><br clear="none">
-The <a shape="rect" href="splitter.html">Splitter</a> will by default return the original input message.</p>
-
-<p><strong>For all versions</strong><br clear="none">
-You can override this by suppling your own strategy as an <code>AggregationStrategy</code>. There is a sample on this page (Split aggregate request/reply sample). Notice its the same strategy as the <a shape="rect" href="aggregator.html">Aggregator</a> supports. This <a shape="rect" href="splitter.html">Splitter</a> can be viewed as having a build in light weight <a shape="rect" href="aggregator.html">Aggregator</a>.</p>
-
-<h3 id="BookInOnePage-Parallelexecutionofdistinct'parts'">Parallel execution of distinct 'parts'</h3>
-<p>If you want to execute all parts in parallel you can use special notation of <code>split()</code> with two arguments, where the second one is a <strong>boolean</strong> flag if processing should be parallel. e.g.</p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
-XPathBuilder xPathBuilder = new XPathBuilder(&quot;//foo/bar&quot;); 
+</div></div><h3 id="BookInOnePage-WhattheSplitterreturns">What the Splitter returns</h3><p><strong>Camel 2.2 or older:</strong><br clear="none"> The <a shape="rect" href="splitter.html">Splitter</a> will by default return the <strong>last</strong> splitted message.</p><p><strong>Camel 2.3 and newer</strong><br clear="none"> The <a shape="rect" href="splitter.html">Splitter</a> will by default return the original input message.</p><p><strong>For all versions</strong><br clear="none"> You can override this by suppling your own strategy as an <code>AggregationStrategy</code>. There is a sample on this page (Split aggregate request/reply sample). Notice its the same strategy as the <a shape="rect" href="aggregator.html">Aggregator</a> supports. This <a shape="rect" href="splitter.html">Splitter</a> can be viewed as having a build in light weight <a shape="rect" href="aggregator.html">Aggregator</a>.</p><h3 id="BookInOnePage-Parallelexecutionofdistinct'parts'">Parallel execution of disti
 nct 'parts'</h3><p>If you want to execute all parts in parallel you can use special notation of <code>split()</code> with two arguments, where the second one is a <strong>boolean</strong> flag if processing should be parallel. e.g.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[XPathBuilder xPathBuilder = new XPathBuilder(&quot;//foo/bar&quot;); 
 from(&quot;activemq:my.queue&quot;).split(xPathBuilder, true).to(&quot;activemq:my.parts&quot;);
 ]]></script>
-</div></div>
-
-<p>The boolean option has been refactored into a builder method <code>parallelProcessing</code> so its easier to understand what the route does when we use a method instead of true|false.</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
-XPathBuilder xPathBuilder = new XPathBuilder(&quot;//foo/bar&quot;); 
+</div></div><p>The boolean option has been refactored into a builder method <code>parallelProcessing</code> so its easier to understand what the route does when we use a method instead of true|false.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[XPathBuilder xPathBuilder = new XPathBuilder(&quot;//foo/bar&quot;); 
 from(&quot;activemq:my.queue&quot;).split(xPathBuilder).parallelProcessing().to(&quot;activemq:my.parts&quot;);
 ]]></script>
-</div></div>
-
-<h3 id="BookInOnePage-Streambased">Stream based</h3>
-    <div class="aui-message hint shadowed information-macro">
+</div></div><h3 id="BookInOnePage-Streambased">Stream based</h3>    <div class="aui-message hint shadowed information-macro">
                     <p class="title">Splitting big XML payloads</p>
                             <span class="aui-icon icon-hint">Icon</span>
                 <div class="message-content">
-                            
-<p>The XPath engine in Java and <a shape="rect" href="xquery.html">saxon</a> will load the entire XML content into memory. And thus they are not well suited for very big XML payloads.<br clear="none">
-Instead you can use a custom <a shape="rect" href="expression.html">Expression</a> which will iterate the XML payload in a streamed fashion. From Camel 2.9 onwards you can use the Tokenizer language<br clear="none">
-which supports this when you supply the start and end tokens.</p>
+                            <p>The XPath engine in Java and <a shape="rect" href="xquery.html">saxon</a> will load the entire XML content into memory. And thus they are not well suited for very big XML payloads.<br clear="none"> Instead you can use a custom <a shape="rect" href="expression.html">Expression</a> which will iterate the XML payload in a streamed fashion. From Camel 2.9 onwards you can use the Tokenizer language<br clear="none"> which supports this when you supply the start and end tokens.</p>
                     </div>
     </div>
-
-
-<p>You can split streams by enabling the streaming mode using the <code>streaming</code> builder method.</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
-    from(&quot;direct:streaming&quot;).split(body().tokenize(&quot;,&quot;)).streaming().to(&quot;activemq:my.parts&quot;);
+<p>You can split streams by enabling the streaming mode using the <code>streaming</code> builder method.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[    from(&quot;direct:streaming&quot;).split(body().tokenize(&quot;,&quot;)).streaming().to(&quot;activemq:my.parts&quot;);
 ]]></script>
-</div></div>
-
-<p>You can also supply your custom splitter to use with streaming like this:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
-import static org.apache.camel.builder.ExpressionBuilder.beanExpression;
+</div></div><p>You can also supply your custom splitter to use with streaming like this:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[import static org.apache.camel.builder.ExpressionBuilder.beanExpression;
 from(&quot;direct:streaming&quot;)
      .split(beanExpression(new MyCustomIteratorFactory(),  &quot;iterator&quot;))
      .streaming().to(&quot;activemq:my.parts&quot;)
 ]]></script>
-</div></div>
-
-<h4 id="BookInOnePage-StreamingbigXMLpayloadsusingTokenizerlanguage">Streaming big XML payloads using Tokenizer language</h4>
-<p><strong>Available as of Camel 2.9</strong><br clear="none">
-If you have a big XML payload, from a file source, and want to split it in streaming mode, then you can use the Tokenizer language with start/end tokens to do this with low memory footprint.</p>
-
-    <div class="aui-message success shadowed information-macro">
+</div></div><h4 id="BookInOnePage-StreamingbigXMLpayloadsusingTokenizerlanguage">Streaming big XML payloads using Tokenizer language</h4><p><strong>Available as of Camel 2.9</strong><br clear="none"> If you have a big XML payload, from a file source, and want to split it in streaming mode, then you can use the Tokenizer language with start/end tokens to do this with low memory footprint.</p>    <div class="aui-message success shadowed information-macro">
                     <p class="title">StAX component</p>
                             <span class="aui-icon icon-success">Icon</span>
                 <div class="message-content">
-                            
-<p>The Camel <a shape="rect" href="stax.html">StAX</a> component can also be used to split big XML files in a streaming mode. See more details at <a shape="rect" href="stax.html">StAX</a>.</p>
+                            <p>The Camel <a shape="rect" href="stax.html">StAX</a> component can also be used to split big XML files in a streaming mode. See more details at <a shape="rect" href="stax.html">StAX</a>.</p>
                     </div>
     </div>
-
-
-<p>For example you may have a XML payload structured as follows</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[
-&lt;orders&gt;
+<p>For example you may have a XML payload structured as follows</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[&lt;orders&gt;
   &lt;order&gt;
     &lt;!-- order stuff here --&gt;
   &lt;/order&gt;
@@ -15773,21 +15582,13 @@ If you have a big XML payload, from a fi
   &lt;/order&gt;
 &lt;/orders&gt;
 ]]></script>
-</div></div>
-
-<p>Now to split this big file using <a shape="rect" href="xpath.html">XPath</a> would cause the entire content to be loaded into memory. So instead we can use the Tokenizer language to do this as follows:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
-  from(&quot;file:inbox&quot;)
+</div></div><p>Now to split this big file using <a shape="rect" href="xpath.html">XPath</a> would cause the entire content to be loaded into memory. So instead we can use the Tokenizer language to do this as follows:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[  from(&quot;file:inbox&quot;)
     .split().tokenizeXML(&quot;order&quot;).streaming()
        .to(&quot;activemq:queue:order&quot;);
 ]]></script>
-</div></div>
-
-<p>In XML DSL the route would be as follows:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[
-&lt;route&gt;
+</div></div><p>In XML DSL the route would be as follows:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[&lt;route&gt;
   &lt;from uri=&quot;file:inbox&quot;/&gt;
   &lt;split streaming=&quot;true&quot;&gt;
     &lt;tokenize token=&quot;order&quot; xml=&quot;true&quot;/&gt;
@@ -15795,21 +15596,13 @@ If you have a big XML payload, from a fi
   &lt;/split&gt;
 &lt;/route&gt;
 ]]></script>
-</div></div>
-
-<p>Notice the <code>tokenizeXML</code> method which will split the file using the tag name of the child node, which mean it will grab the content between the <code>&lt;order&gt;</code> and <code>&lt;/order&gt;</code> tags (incl. the tokens). So for example a splitted message would be as follows:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[
-  &lt;order&gt;
+</div></div><p>Notice the <code>tokenizeXML</code> method which will split the file using the tag name of the child node, which mean it will grab the content between the <code>&lt;order&gt;</code> and <code>&lt;/order&gt;</code> tags (incl. the tokens). So for example a splitted message would be as follows:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[  &lt;order&gt;
     &lt;!-- order stuff here --&gt;
   &lt;/order&gt;
 ]]></script>
-</div></div>
-
-<p>If you want to inherit namespaces from a root/parent tag, then you can do this as well by providing the name of the root/parent tag:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[
-&lt;route&gt;
+</div></div><p>If you want to inherit namespaces from a root/parent tag, then you can do this as well by providing the name of the root/parent tag:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[&lt;route&gt;
   &lt;from uri=&quot;file:inbox&quot;/&gt;
   &lt;split streaming=&quot;true&quot;&gt;
     &lt;tokenize token=&quot;order&quot; inheritNamespaceTagName=&quot;orders&quot; xml=&quot;true&quot;/&gt;
@@ -15817,34 +15610,18 @@ If you have a big XML payload, from a fi
   &lt;/split&gt;
 &lt;/route&gt;
 ]]></script>
-</div></div>
-
-<p>And in Java DSL its as follows:</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
-  from(&quot;file:inbox&quot;)
+</div></div><p>And in Java DSL its as follows:</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[  from(&quot;file:inbox&quot;)
     .split().tokenizeXML(&quot;order&quot;, &quot;orders&quot;).streaming()
        .to(&quot;activemq:queue:order&quot;);
 ]]></script>
-</div></div>
-
-
-<h4 id="BookInOnePage-SplittingfilesbygroupingNlinestogether">Splitting files by grouping N lines together</h4>
-<p><strong>Available as of Camel 2.10</strong></p>
-
-<p>The <a shape="rect" href="tokenizer.html">Tokenizer</a> language has a new option <code>group</code> that allows you to group N parts together, for example to split big files into chunks of 1000 lines.</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[
-  from(&quot;file:inbox&quot;)
+</div></div><p><span style="line-height: 1.4285715;">Available as of Camel 2.13.1, you can set the above inheritNamsepaceTagName property to "*" to&#160;include the preceding context in each token (i.e., generating each token enclosed in its ancestor elements).</span></p><h4 id="BookInOnePage-SplittingfilesbygroupingNlinestogether">Splitting files by grouping N lines together</h4><p><strong>Available as of Camel 2.10</strong></p><p>The <a shape="rect" href="tokenizer.html">Tokenizer</a> language has a new option <code>group</code> that allows you to group N parts together, for example to split big files into chunks of 1000 lines.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: java; gutter: false" type="syntaxhighlighter"><![CDATA[  from(&quot;file:inbox&quot;)
     .split().tokenize(&quot;\n&quot;, 1000).streaming()
        .to(&quot;activemq:queue:order&quot;);
 ]]></script>
-</div></div>
-
-<p>And in XML DSL</p>
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[
-&lt;route&gt;
+</div></div><p>And in XML DSL</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<script class="theme: Default; brush: xml; gutter: false" type="syntaxhighlighter"><![CDATA[&lt;route&gt;
   &lt;from uri=&quot;file:inbox&quot;/&gt;
   &lt;split streaming=&quot;true&quot;&gt;
     &lt;tokenize token=&quot;\n&quot; group=&quot;1000&quot;/&gt;
@@ -15852,24 +15629,8 @@ If you have a big XML payload, from a fi
   &lt;/split&gt;
 &lt;/route&gt;
 ]]></script>
-</div></div>
-
-<p>The <code>group</code> option is a number that must be a positive number that dictates how many groups to combine together. Each part will be combined using the token.<br clear="none">
-So in the example above the message being sent to the activemq order queue, will contain 1000 lines, and each line separated by the token (which is a new line token).<br clear="none">
-The output when using the <code>group</code> option is always a <code>java.lang.String</code> type. </p>
-
-
-
-<h4 id="BookInOnePage-Specifyingacustomaggregationstrategy">Specifying a custom aggregation strategy </h4>
-
-<p>This is specified similar to the <a shape="rect" href="aggregator.html">Aggregator</a>.</p>
-
-<h4 id="BookInOnePage-SpecifyingacustomThreadPoolExecutor">Specifying a custom ThreadPoolExecutor</h4>

[... 372 lines stripped ...]


Mime
View raw message