activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gary Tully" <gary.tu...@gmail.com>
Subject Re: How to intercept the creation of ActiveMQConnections?
Date Wed, 03 Sep 2008 08:38:02 GMT
yea, intercept the accept listener for the TcpTransportConnector.

This would be a nice feature to help throttle cpu usage by the broker.
Imagine a hardware load balancer infront of a bunch of brokers,
setting a max_concurrent_connections limit on the
TcpTransportConnector would allow the loadbalancer to redistribute the
connection attempt to another broker and each broker could be limited
as appropriate.
To maintain a count of active connections, it will be necessary to
track connection close events also of course.
Nearly seems like a job for a server socket factory.


2008/9/3 Hiram Chirino <hiram@hiramchirino.com>:
> Then your going to have to stop/suspend the Accept thread for the
> server socket or accept the connection but then shut it down.
>
> On Tue, Sep 2, 2008 at 5:55 PM, Bruce Snyder <bruce.snyder@gmail.com> wrote:
>> On Tue, Sep 2, 2008 at 3:37 PM, Hiram Chirino <hiram@hiramchirino.com> wrote:
>>> AOP won't help since the client is going to be in a different JVM the
>>> server.  So there is no server logic that can control the client until
>>> the client connects.. and it seems your too late at that point.
>>
>> I'm not looking to control connections from the client side. I want to
>> be able to limit the number of client connections from the broker
>> side.
>>
>> Bruce
>> --
>> perl -e 'print unpack("u30","D0G)U8V4\@4VYY9&5R\"F)R=6-E+G-N>61E<D\!G;6%I;\"YC;VT*"
>> );'
>>
>> Apache ActiveMQ - http://activemq.org/
>> Apache Camel - http://activemq.org/camel/
>> Apache ServiceMix - http://servicemix.org/
>>
>> Blog: http://bruceblog.org/
>>
>
>
>
> --
> Regards,
> Hiram
>
> Blog: http://hiramchirino.com
>
> Open Source SOA
> http://open.iona.com
>

Mime
View raw message