You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by bu...@apache.org on 2015/08/28 16:21:13 UTC

svn commit: r963371 - in /websites/production/activemq/content: cache/main.pageCache consumer-dispatch-async.html

Author: buildbot
Date: Fri Aug 28 14:21:12 2015
New Revision: 963371

Log:
Production update by buildbot for activemq

Modified:
    websites/production/activemq/content/cache/main.pageCache
    websites/production/activemq/content/consumer-dispatch-async.html

Modified: websites/production/activemq/content/cache/main.pageCache
==============================================================================
Binary files - no diff available.

Modified: websites/production/activemq/content/consumer-dispatch-async.html
==============================================================================
--- websites/production/activemq/content/consumer-dispatch-async.html (original)
+++ websites/production/activemq/content/consumer-dispatch-async.html Fri Aug 28 14:21:12 2015
@@ -36,6 +36,7 @@
       <link href='http://activemq.apache.org/styles/highlighter/styles/shThemeEclipse.css' rel='stylesheet' type='text/css' /> 
       <script src='http://activemq.apache.org/styles/highlighter/scripts/shCore.js' type='text/javascript'></script> 
               <script src='http://activemq.apache.org/styles/highlighter/scripts/shBrushJava.js' type='text/javascript'></script> 
+              <script src='http://activemq.apache.org/styles/highlighter/scripts/shBrushXml.js' type='text/javascript'></script> 
          
       <script type="text/javascript"> 
         SyntaxHighlighter.defaults['toolbar'] = false; 
@@ -81,42 +82,17 @@
   <tbody>
         <tr>
         <td valign="top" width="100%">
-<div class="wiki-content maincontent"><h2 id="ConsumerDispatchAsync-Overview">Overview</h2>
-
-<p>In AMQ4, the choice of a broker performing synchronous or asynchronous dispatch to a consumer has become more configurable.  It is now configured as a default value on the <a shape="rect" href="connection-configuration-uri.html">connection URI, Connection and ConnectionFactory</a> together with being customizable on a per consumer basis via the <a shape="rect" href="destination-options.html">Destination Options</a> instead previously just being a transport server setting.  </p>
-
-<p>This makes more sense since you want to do async message delivery to slower consumers, but do sync message delivery to faster consumers (to avoid the synchronization and context switching costs of adding another seda queue).  The downside to using sync message delivery is that the producer is more likely to block if there is a slow consumer that he is dispatching messages to.</p>
-
-<p>The default setting is dispatchAsync=true which is the best setting for high performance. If you want to deal better with slow consumers you will want to enable this setting. If you want better thoughput and the chances of having a slow consumer are low, you may want to change this to false.</p>
-
-<h3 id="ConsumerDispatchAsync-ConfiguringAsyncDispatchattheConnectionFactoryLevel">Configuring Async Dispatch at the ConnectionFactory Level</h3>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<pre class="brush: java; gutter: false; theme: Default" style="font-size:12px;">
-((ActiveMQConnectionFactory)connectionFactory).setDispatchAsync(false);
+<div class="wiki-content maincontent"><h2 id="ConsumerDispatchAsync-Overview">Overview</h2><p>In AMQ4, the choice of a broker performing synchronous or asynchronous dispatch to a consumer has become more configurable. It is now configured as a default value on the <a shape="rect" href="connection-configuration-uri.html">connection URI, Connection and ConnectionFactory</a> together with being customizable on a per consumer basis via the <a shape="rect" href="destination-options.html">Destination Options</a> instead previously just being a transport server setting.</p><p>This makes more sense since you want to do async message delivery to slower consumers, but do sync message delivery to faster consumers (to avoid the synchronization and context switching costs of adding another seda queue). The downside to using sync message delivery is that the producer is more likely to block if there is a slow consumer that he is dispatching messages to.</p><p>The default setting is dispatchAsync=
 true which is the best setting for high performance. If you want to deal better with slow consumers you will want to enable this setting. If you want better thoughput and the chances of having a slow consumer are low, you may want to change this to false.</p><h3 id="ConsumerDispatchAsync-ConfiguringAsyncDispatchattheConnectionFactoryLevel">Configuring Async Dispatch at the ConnectionFactory Level</h3><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<pre class="brush: java; gutter: false; theme: Default" style="font-size:12px;">((ActiveMQConnectionFactory)connectionFactory).setDispatchAsync(false);
 </pre>
-</div></div>
-
-<h3 id="ConsumerDispatchAsync-ConfiguringDispatchAsyncattheConnectionLevel">Configuring Dispatch Async at the Connection Level</h3>
-
-<p>Configuring the dispatchAsync setting at this level overrides the settings at the connection factory level.</p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<pre class="brush: java; gutter: false; theme: Default" style="font-size:12px;">
-((ActiveMQConnection)connection).setDispatchAsync(false);
-</pre>
-</div></div>
-
-<h3 id="ConsumerDispatchAsync-ConfiguringDispatchAsyncattheConsumerLevelusingtheDestinationURI">Configuring Dispatch Async at the Consumer Level using the Destination URI</h3>
-
-<p>Configuring the dispatchAsync using <a shape="rect" href="destination-options.html">Destination Options</a> overrides the settings at the connection and connection factory level.</p>
-
-<div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
-<pre class="brush: java; gutter: false; theme: Default" style="font-size:12px;">
-queue = new ActiveMQQueue("TEST.QUEUE?consumer.dispatchAsync=false");
+</div></div><h3 id="ConsumerDispatchAsync-ConfiguringDispatchAsyncattheConnectionLevel">Configuring Dispatch Async at the Connection Level</h3><p>Configuring the dispatchAsync setting at this level overrides the settings at the connection factory level.</p><h3 id="ConsumerDispatchAsync-ConfiguringDispatchAsyncattheConsumerLevelusingtheDestinationURI">Configuring Dispatch Async at the Consumer Level using the Destination URI</h3><p>Configuring the dispatchAsync using <a shape="rect" href="destination-options.html">Destination Options</a> overrides the settings at the connection and connection factory level.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<pre class="brush: java; gutter: false; theme: Default" style="font-size:12px;">queue = new ActiveMQQueue("TEST.QUEUE?consumer.dispatchAsync=false");
 consumer = session.createConsumer(queue);
 </pre>
-</div></div></div>
+</div></div><h3 id="ConsumerDispatchAsync-DisablingAsyncDispatchonBroker'sTransportConnector">Disabling Async Dispatch on Broker's Transport Connector</h3><p>It is possible to disable async dispatch on a specific transport connector via the disableAsyncDispatch property. Once disabled for this transport, it cannot be enabled by individual clients.</p><div class="code panel pdl" style="border-width: 1px;"><div class="codeContent panelContent pdl">
+<pre class="brush: xml; gutter: false; theme: Default" style="font-size:12px;">&lt;transportConnector name="openwire" uri="tcp://0.0.0.0:61616" disableAsyncDispatch="true" /&gt;
+</pre>
+</div></div><p>&#160;</p><p>&#160;</p><p>&#160;</p></div>
         </td>
         <td valign="top">
           <div class="navigation">