activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From davidmc <aranman...@gmail.com>
Subject Re: AMQCPP Openwire much slower than Stomp?
Date Fri, 20 Apr 2007 01:15:11 GMT

No, right now the broker side is not implementing this correctly.
See AMQ-1156 : https://issues.apache.org/activemq/browse/AMQ-1156 and also
the discussion at AMQ-1137:
https://issues.apache.org/activemq/browse/AMQ-1137.

The easiest solution right now is to go to the method
org.apache.activemq.transport.tcp.TcpTransport.initialiseSocket method and
add the line "sock.setTcpNoDelay(true);" at the end.

I have been looking further into this, and have found that the problem lies
around the TcpTransportServer class.
I have to run to a meeting, more details later :)


Teemu Torma wrote:
> 
> On Thursday 19 April 2007, Albert Strasheim wrote:
>> From what I can tell, AMQCPP supports a broker URL property for
>> setting TCP_NODELAY, but actually setting it doesn't change anything
>> at socket creation time (although I could be mistaken, I just did a
>> quick browse through the code). Maybe TCP_NODELAY should even be the
>> default?
> 
> You need activemq side to do the same thing to get latency down.  On the 
> other hand, if you are just sending messages you get better throughput 
> without TCP_NODELAY, it all depends on usage.
> 
>> > How to check if this is really the problem:
>> > -Go to AMQCPP source code and add a line to your socket creation
>> > code, where you explicitely set TCP_NODELAY to True always (to
>> > disable Nagle's algorithm). Rebuild and compare.
>>
>> I'll give this a go today.
> 
> I tested this earlier this week and did get 40ms off from the round-trip 
> time (all Linux).  However, I still get 40ms left and even though 
> tracing openwire commands show we are requesting nodelay from the 
> broker, I could not get it down.  Does activemq itself implement this 
> correctly?
> 
> Teemu
> 
> 

-- 
View this message in context: http://www.nabble.com/AMQCPP-Openwire-much-slower-than-Stomp--tf3599986s2354.html#a10089917
Sent from the ActiveMQ - Dev mailing list archive at Nabble.com.


Mime
View raw message