activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Timothy Bish <tim.b...@sensis.com>
Subject RE: Implementation of multithreading model on CMS ActiveMQ
Date Mon, 21 May 2007 18:09:10 GMT
You could try pulling the latest code from trunk to see what effect the
TCP_NODELAY option will have on performance on your machine.  The code
in trunk sets TCP_NODELAY on by default.

regards
Tim

On Mon, 2007-05-21 at 10:52 -0700, Pravin Kundal wrote:
> Hey Sir, the string you sent "WORKED"..........thanks!!
> 
> Stomp improved the results but still away from our target. posting some
> results. Message was string of around size 50 to 70 characters. All with
> Non_Persistent message relibility (i.e. atmost once)
> 
> Here are our readings:
> A]
> Using Openwire, Asynchronous Consumer. 
>   1] Multi Threading : one session, one producer per Thread:     214
> msges/sec.
>   2] Multi Threading : one session, mutiple producers. concurrency
> implemented in client:     122 
>       msges/sec.
> 
> B] 
> 1) Using Stomp, Asynchronous Consumer. 
> 
>   1] Single Thread:      410 msges/sec.
>   2] Multi Threading (2 Threads): one session, one producer per Thread:    
> 357 msges/sec.
>   3] Multi Threading (5 Threads): one session, one producer per Thread:    
> 413 msges/sec.
>   4] Multi Threading (5 Threads): one session, one producer per Thread:    
> 387 msges/sec.
> 
> 2) Using Stomp, Synchronous Consumer. 
>  
>   1] Single Thread:      367 msges/sec.
> 
> So from the above results maximum is 413 what we got. Our target is upto 600
> to 650 msges/sec.
> 
> Also both producer and consumer are CMS ActiveMQ.
> 
> Our Java team tested using Java clients (producer and consumer) with
> ActiveMQ broker with 10 threads running they are getting around 700
> msges/sec. Is it because java supports internal multithreading or something
> else. Or any other reason????
> 
> I really appreciate for you quick and working out responses :) Thanks.
> 
> 
> 
> 
> Mittler, Nathan wrote:
> > 
> > Sorry ... The url should be "tcp://localhost:61613?wireFormat=stomp"
> > 
> > See http://activemq.apache.org/cms/configuring.html 
> > 
> >> -----Original Message-----
> >> From: Pravin Kundal [mailto:pravin_kundal@persistent.co.in] 
> >> Sent: Monday, May 21, 2007 12:34 PM
> >> To: users@activemq.apache.org
> >> Subject: RE: Implementation of multithreading model on CMS ActiveMQ
> >> 
> >> 
> >> I am trying to test it out using stomp.
> >> But it is giving me exceptions
> >> On Consumer Client: ActiveMQConnectionFactory - unknown 
> >> Transport Factory.
> >> 
> >> I tried with following brokerURI's
> >> 
> >> std::string brokerURI =   "stomp://localhost:61613"
> >>                                      "?wireFormat=stomp"
> >> 		           "&transport.useAsyncSend=true";
> >> 
> >> std::string brokerURI =   "stomp://localhost:61613"
> >> 
> >> std::string brokerURI =   "stomp://localhost:61616"
> >> 
> >> can you please help us out?
> >> 
> >> Thanks.
> >> 
> >> 
> >> 
> >> Mittler, Nathan wrote:
> >> > 
> >> >  
> >> >> 
> >> >> In the case I will need to implement the concurrency 
> >> control over the 
> >> >> session, so that only one thread can use the session, as 
> >> sessions are 
> >> >> implemented for serial use? Rght?
> >> > 
> >> > Yes, you should add your own concurrency control for the session.
> >> > 
> >> >> 
> >> >> I tried the first case in which i implemented the multithreading, 
> >> >> each thread running its own session and each session having one 
> >> >> producer. But the results were not even close to our requriment 
> >> >> (result in msges/sec).
> >> >> 
> >> > 
> >> > Were you using openwire or stomp as the protocol?  We have 
> >> seen cases 
> >> > where small messages with openwire cause extra delay due to 
> >> the naggle 
> >> > algorithm and that message footprints are smaller than their stomp 
> >> > counterpart.  If you're using openwire, I suggest you 
> >> switch over to 
> >> > stomp and see if you have different results.  If that does 
> >> the trick, 
> >> > our next release will allow a user-specified TCP-NODELAY 
> >> socket option 
> >> > that should fix the problem for openwire (for small messages).
> >> > 
> >> >> Do you think the other case can give us the better results 
> >> (i.e. "The 
> >> >> ActiveMQ-CPP implementation, however, will allow you to share a 
> >> >> session across threads.")
> >> >> 
> >> > 
> >> > Without understanding your particular usage of the client, I would 
> >> > guess that a different usage wouldn't help much.  Just to 
> >> make sure, 
> >> > however, you could slightly modify our example application 
> >> > 
> >> https://svn.apache.org/repos/asf/activemq/activemq-cpp/trunk/src/examp
> >> > le s/main.cpp and see if you can get it to meet your requirements.
> >> > 
> >> > 
> >> > Regards,
> >> > Nate
> >> > 
> >> > 
> >> 
> >> --
> >> View this message in context: 
> >> http://www.nabble.com/Implementation-of-multithreading-model-o
> >> n-CMS-ActiveMQ-tf3790047s2354.html#a10722340
> >> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
> >> 
> >> 
> > 
> > 
> 

Mime
View raw message