You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@thrift.apache.org by Rush Manbert <ru...@manbert.com> on 2009/05/20 03:08:34 UTC

TNonblockingServer performance

Has anyone else built the non-blocking version of the C++ stress-test?  
When I run it with a client count of 20 and a loop count of 100 I see  
a rate value of about 395.

With the blocking version and the same parameters I see a rate between  
28000 and 34000, depending on the server type.

The TNonblockingServer header says this is a server for high  
performance, but that's not what I'm seeing. I'm on Mac OS X 10.5.6.

Is there anyone else who is getting different results?

- Rush

Re: TNonblockingServer performance

Posted by Rush Manbert <ru...@manbert.com>.
Hi Jake,
That made a big difference.  Here are some numbers:

Clients     Loops       usleep(5000)    server=thread-pool  rate
-------     -----       ------------    ------------------  ----
20          100         In              No                  395
20          100         In              Yes                 792
100         100         In              Yes                 793
100         100         Out             Yes                 14925
500         100         Out             Yes                 14500 to  
17700 (4 to 128 workers)
100         100         Out             No                  30769
300         500         Out             No                  29874

Do these seem reasonable to you? I guess it makes sense that the  
separate thread setup costs more than it gains in performance when the  
thread does nothing. (These are the maximum client counts I could use,  
despite an open file limit of 10000.)

- Rush

On May 20, 2009, at 3:23 AM, Jake Luciani wrote:

> there is a usleep(5000) in the client operation for just this test.   
> i added
> this a long time ago to show the half-sync/half-async works.
>
> you can comment it out or if you specify --server-type=thread-pool  
> it will
> use async for io but threads for processing.
>
> -Jake
>
> On Wed, May 20, 2009 at 5:45 AM, Rory McGuire  
> <rm...@neonova.co.za>wrote:
>
>> I haven't used it, but non-blocking IO should out perform blocking IO
>> when you have more clients (try 10000).
>>
>> -Rory
>>
>>
>>
>> On Tue, 2009-05-19 at 18:08 -0700, Rush Manbert wrote:
>>
>>> Has anyone else built the non-blocking version of the C++ stress- 
>>> test?
>>> When I run it with a client count of 20 and a loop count of 100 I  
>>> see
>>> a rate value of about 395.
>>>
>>> With the blocking version and the same parameters I see a rate  
>>> between
>>> 28000 and 34000, depending on the server type.
>>>
>>> The TNonblockingServer header says this is a server for high
>>> performance, but that's not what I'm seeing. I'm on Mac OS X 10.5.6.
>>>
>>> Is there anyone else who is getting different results?
>>>
>>> - Rush
>>


Re: TNonblockingServer performance

Posted by Jake Luciani <ja...@gmail.com>.
there is a usleep(5000) in the client operation for just this test.  i added
this a long time ago to show the half-sync/half-async works.

you can comment it out or if you specify --server-type=thread-pool it will
use async for io but threads for processing.

-Jake

On Wed, May 20, 2009 at 5:45 AM, Rory McGuire <rm...@neonova.co.za>wrote:

> I haven't used it, but non-blocking IO should out perform blocking IO
> when you have more clients (try 10000).
>
> -Rory
>
>
>
> On Tue, 2009-05-19 at 18:08 -0700, Rush Manbert wrote:
>
> > Has anyone else built the non-blocking version of the C++ stress-test?
> > When I run it with a client count of 20 and a loop count of 100 I see
> > a rate value of about 395.
> >
> > With the blocking version and the same parameters I see a rate between
> > 28000 and 34000, depending on the server type.
> >
> > The TNonblockingServer header says this is a server for high
> > performance, but that's not what I'm seeing. I'm on Mac OS X 10.5.6.
> >
> > Is there anyone else who is getting different results?
> >
> > - Rush
>

Re: TNonblockingServer performance

Posted by Rory McGuire <rm...@neonova.co.za>.
I haven't used it, but non-blocking IO should out perform blocking IO
when you have more clients (try 10000).

-Rory



On Tue, 2009-05-19 at 18:08 -0700, Rush Manbert wrote: 

> Has anyone else built the non-blocking version of the C++ stress-test?  
> When I run it with a client count of 20 and a loop count of 100 I see  
> a rate value of about 395.
> 
> With the blocking version and the same parameters I see a rate between  
> 28000 and 34000, depending on the server type.
> 
> The TNonblockingServer header says this is a server for high  
> performance, but that's not what I'm seeing. I'm on Mac OS X 10.5.6.
> 
> Is there anyone else who is getting different results?
> 
> - Rush