[ 
https://issues.apache.org/activemq/browse/AMQ-905?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Rob Davies resolved AMQ-905.
----------------------------

    Fix Version/s: 5.1.0
                       (was: 5.2.0)
       Resolution: Fixed

> A single JMS Listener is way too slow
> -------------------------------------
>
>                 Key: AMQ-905
>                 URL: https://issues.apache.org/activemq/browse/AMQ-905
>             Project: ActiveMQ
>          Issue Type: Bug
>    Affects Versions: 4.0.1
>            Reporter: Daniel Aioanei
>            Assignee: Rob Davies
>             Fix For: 5.1.0
>
>         Attachments: activemq.xml
>
>
> I'm using ActiveMQ 4.0.1 with a DerbyDB backend and I have a single JMS 
> listener for a queue with loads of messages. In order to see how many 
> msg/second are processed by a no-op JMS listener, with a single concurrent 
> session, I used the following configuration:
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" 
>     "http://www.springframework.org/dtd/spring-beans.dtd";>
> <beans>
>   <!-- START SNIPPET: jca -->
>   <bean id="jencks" class="org.jencks.JCAContainer">
>     <!-- lets use the default configuration of work manager and transaction 
> manager-->
>     <property name="bootstrapContext">
>       <bean class="org.jencks.factory.BootstrapContextFactoryBean">
>         <property name="threadPoolSize" value="200"/>
>       </bean>
>     </property>
>     <!-- the JCA Resource Adapter -->
>     <property name="resourceAdapter">
>       <bean id="activeMQResourceAdapter" 
> class="org.apache.activemq.ra.ActiveMQResourceAdapter">
>         <property name="serverUrl" 
> value="tcp://localhost:61616?wireFormat.cacheEnabled=false&amp;wireFormat.tightEncodingEnabled=false&amp;jms.useAsyncSend=false"/>
>       </bean>
>     </property>
>   </bean>
>   <!-- END SNIPPET: jca -->
>   <!--
>     || an inbound message connector using a stateless, thread safe 
> MessageListener
>     -->
>   <!-- START SNIPPET: inbound -->
>   
>   <bean id="inboundConnectorA" class="org.jencks.JCAConnector">
>     <property name="jcaContainer" ref="jencks" />
>     <!-- subscription details -->
>     <property name="activationSpec">
>       <bean class="org.apache.activemq.ra.ActiveMQActivationSpec">
>         <property name="destination" value="queue/MyQueue"/>
>         <property name="destinationType" value="javax.jms.Queue"/>
>         <property name="acknowledgeMode" value="Auto-acknowledge"/>
>         <property name="useRAManagedTransaction" value="false"/>
>         
>               <property name="maximumRedeliveries" value="10"/>
>               <property name="initialRedeliveryDelay" value="1000"/>
>               <property name="useExponentialBackOff" value="true"/>
>               <property name="backOffMultiplier" value="5"/>
>               
>         <property name="maxSessions" value="1"/>
>         <property name="maxMessagesPerSessions" value="1"/>
>       </bean>
>     </property>
>     <property name="ref" value="testOutboundMdp"/>
>   </bean>
>       <bean id="testOutboundMdp" class="TestOutboundMdp"/>
>   
> </beans>
> The problem is that the consumption speed is 11 msg/second and cpu 
> consumption is about 1-2%. To get almost 100% cpu usage I have to increase 
> threadPoolSize and maximumRedeliveries to 1000 (!) and at that point the 
> consumption speed reaches 142 msg/sec, which is not too impressive either. 
> I'm not sure if it's a Jencks or ActiveMQ issue here.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to