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 15:51:56 GMT
But if you only want AMQ to utilise say 40% of cpu resources (cause it
is not the only beast on the box), can I tell my hardware loadbalancer
that I only want say 40 connections per broker? If not, then the
ability to configure a limit on the number of connections and reject
those in excess would be handy.
Is there any other way to limit/throttle CPU utilisation with AMQ?

2008/9/3 Hiram Chirino <hiram@hiramchirino.com>:
> Most hardware load balancers will keep track of the active TCP
> sessions against a server so there really is no need to reject
> connections.  The will spread the load onto servers with the fewest
> active connections.  This is more of feature for when there is NO load
> balancer in play.
>
> On Wed, Sep 3, 2008 at 4:38 AM, Gary Tully <gary.tully@gmail.com> wrote:
>> 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
>>>
>>
>
>
>
> --
> Regards,
> Hiram
>
> Blog: http://hiramchirino.com
>
> Open Source SOA
> http://open.iona.com
>

Mime
View raw message