Hi,

the pooled connection factory will try to create maxConnections
(default 1) and then reuse them from the pool. The process of
connections creating (failover and randomize) is not related to the
pool at all. With failover in case, the client (and the pool) will not
even see host1 connection problem as transport itself will reconnect
to host2.


Regards
-- 
Dejan Bosanac
Senior Software Engineer | FuseSource Corp.
dej...@fusesource.com | fusesource.com
skype: dejan.bosanac | twitter: @dejanb
blog: http://www.nighttale.net
ActiveMQ in Action: http://www.manning.com/snyder/


On Fri, Jul 27, 2012 at 12:16 AM, Gaurav Sharma
<gaurav.cs.sha...@gmail.com> wrote:
> It seems like with a failover transport configuration
> (failover:(nio:host1:port1,nio:host2:port2)?randomize=false) and a
> PooledConnectionFactory, the client-side still tries to create a new
> connection per thread instead of fetching from the pool of connections.
> With 'randomize' flag turned off, I would think that the pool can keep
> connections to the primary broker node, no? Then, if host1 goes down, drain
> the pool and fill it up with host2 connections upto the maxActive limit. Is
> that how it is supposed to work or am I expecting too much intelligence in
> the pooled conexn factory?
>
> -gaurav

Reply via email to