Its always a good idea to use pooled connection factory with a JMS
broker. It improves performance and avoids creating and stopping
connections all the time which eats up resources as well.

Also reusing sessions/consumers can speedup as well, there is the
cacheLevelName option on the JMS component to configure this.

Take a look at
http://camel.apache.org/jms

And pay attention to that transacted and cacheLevelName.

And if you do request/reply over JMS then there is also some options
about what kind of replyToType you are using.

And for ActiveMQ there is a sample about using its connection pool at
http://activemq.apache.org/

And spring framework also has a connection pool out of the box you can
use. See the spring docs about that one.

On Tue, Oct 29, 2013 at 12:10 PM, Dayakar <daya.kond...@gmail.com> wrote:
> Hi,
>
> Previously we are using ActiveMQConnectionFactory alone, and we observed
> that while starting the JBoss Server ActiveMQ is creating multiple threads
> and closing (ActiveMQ Task 1, ActiveMQ Task 2, ...), we thought it creating
> multiple connections/session are creating and closing.
>
> As a resolution, we want to use PooledConnectionFactory
>
> 1) We are using Camel Routes to prepare and send messages to destination, we
> invoke 7 routes and each route configured with parallel processing (Min
> value is 5 and max value is 25 threads), daily we process around 3 Lakh
> Messages (= 300.000) and All Routes are TRANSACTED.
>
> In Parallel Processing Is it better to use PooledConnectionFactory?
>
> For Each Message PooledConnectionFactory create one session (or) Session
> object will be shared by Multiple messages?
>
>
>
>
>
> --
> View this message in context: 
> http://camel.465427.n5.nabble.com/Is-it-better-to-use-PooledConnectionFactory-in-Parallel-Processing-tp5742350.html
> Sent from the Camel - Users mailing list archive at Nabble.com.



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
Email: cib...@redhat.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Reply via email to