L.S.,

That ConnectionFactory instance delegates to the poolingSupport
defined in conf/tx.xml for defining the connection pool sizes.  You
can add <property> elements for adding minSize, maxSize, ... (you can
take a quick peek at
http://activemq.apache.org/jms-and-jdbc-operations-in-one-transaction.html
for seeing some of the options available).

Instead of reusing the same connection pool as is being used by
ServiceMix internally, you could also define your own connection pool
for the JMS Provider endpoint (cfr. Working with Spring's JmsTemplate
on http://activemq.apache.org/spring-support.html)

Regards,

Gert Vanthienen
------------------------
Open Source SOA: http://fusesource.com
Blog: http://gertvanthienen.blogspot.com/



On 1 March 2010 19:34, subh <[email protected]> wrote:
>
> Hi,
>
> I have the default activeMq connection factory configured as below,
>
> ...........
> ..........
>     <!-- jndi entry for ActiveMQ connection factory -->
>    <entry key="amqConnectionFactory" value-ref="activemqConnectionFactory"
> />
>
>  </util:map>
>
>  <!-- A managed JMS ConnectionFactory for ActiveMQ -->
>  <amqra:managedConnectionFactory
>          id="activemqMCF"
>          resourceAdapter="#activemqRA" />
>  <amqra:resourceAdapter
>          id="activemqRA"
>
> serverUrl="tcp://${activemq.orsesb.host}:${activemq.orsesb.port}"/>
>  <jencks:connectionFactory
>          id="activemqConnectionFactory"
>          managedConnectionFactory="#activemqMCF"
>          connectionManager="#connectionManager" />
>
> But when the incoming messages load increases, I occasionally get the below
> exception..what are the ways to avoid it..I read somewhere to increase the
> max connections parameter, or increase the timeout parameter or even use
> 'selectOneAssumeMatch' flag in the pool. Can anyone suggest ways to do these
> configurations..
>
> org.springframework.jms.UncategorizedJmsException: Uncategorized exception
> occured during JMS processing; nested exception is javax.jms.JMSException:
> No ManagedConnections available within configured blocking timeout ( 5000
> [ms] ) for pool
> org.apache.geronimo.connector.outbound.singlepoolconnectionintercep...@19a630b
>        at
> org.springframework.jms.support.JmsUtils.convertJmsAccessException(JmsUtils.java:308)
>        at
> org.springframework.jms.support.JmsAccessor.convertJmsAccessException(JmsAccessor.java:168)
>        at 
> org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:474)
>        at
> org.apache.servicemix.jms.endpoints.JmsProviderEndpoint.processInOnly(JmsProviderEndpoint.java:542)
>        at
> org.apache.servicemix.jms.endpoints.JmsProviderEndpoint.process(JmsProviderEndpoint.java:499)
>        at
> org.apache.servicemix.common.AsyncBaseLifeCycle.doProcess(AsyncBaseLifeCycle.java:627)
>        at
> org.apache.servicemix.common.AsyncBaseLifeCycle.processExchange(AsyncBaseLifeCycle.java:581)
>        at
> org.apache.servicemix.common.AsyncBaseLifeCycle.onMessageExchange(AsyncBaseLifeCycle.java:535)
>        at
> org.apache.servicemix.common.SyncLifeCycleWrapper.onMessageExchange(SyncLifeCycleWrapper.java:60)
>        at
> org.apache.servicemix.jbi.messaging.DeliveryChannelImpl.processInBound(DeliveryChannelImpl.java:623)
>        at
> org.apache.servicemix.jbi.nmr.flow.AbstractFlow.doRouting(AbstractFlow.java:172)
>        at
> org.apache.servicemix.jbi.nmr.flow.seda.SedaFlow.doRouting(SedaFlow.java:168)
>        at
> org.apache.servicemix.jbi.nmr.flow.seda.SedaQueue$1.run(SedaQueue.java:134)
>        at
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
>        at
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
>        at java.lang.Thread.run(Thread.java:619)
> --
> View this message in context: 
> http://old.nabble.com/No-ManagedConnections-available-within-configured-blocking-timeout-%28-5000--ms--%29-tp27747340p27747340.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>
>

Reply via email to