[Twisted-web] PB vs Foolscap vs AMP?

gelin yan dynamicgl at gmail.com
Sat Mar 10 01:07:38 EST 2012


On Fri, Mar 9, 2012 at 6:54 AM, Jacek Furmankiewicz <jacek99 at gmail.com>wrote:

> Great, thanks! It would be great if someone had done comparisons with
> txZMQ <https://github.com/smira/txZMQ> as well
> but I guess I'll have to play with that myself.
>
> Jacek
>
> On Thu, Mar 8, 2012 at 5:50 PM, Glyph Lefkowitz <glyph at twistedmatrix.com>wrote:
>
>>
>> On Mar 8, 2012, at 2:45 PM, Jacek Furmankiewicz wrote:
>>
>> I am trying to do some research on what is the most performant method for
>> a Twisted server to speak to a client running in a separate process.
>>
>>
>> The default solution in Twisted seems to be Perspective Broker, but then
>> there is AMP and Foolscap as well.
>>
>> Has anyone ever done any benchmarks comparing those? I'd like to have an
>> idea as to which one is most likely to give me the best performance.
>>
>>
>> AMP is fastest.  It's not really possible to *directly* compare, because
>> PB and Foolscap respectively have more features, but compare here:
>>
>>
>> http://speed.twistedmatrix.com/timeline/?exe=2%2C4&base=none&ben=pb&env=d3&revs=200
>>
>> and
>>
>>
>> http://speed.twistedmatrix.com/timeline/?exe=2%2C4&base=none&ben=amp&env=d3&revs=200
>>
>> You're of course welcome to contribute optimizations to PB :).
>>
>> -glyph
>>
>>
>> _______________________________________________
>> Twisted-web mailing list
>> Twisted-web at twistedmatrix.com
>> http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-web
>>
>>
>
> _______________________________________________
> Twisted-web mailing list
> Twisted-web at twistedmatrix.com
> http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-web
>
>
Based on my experience, AMP is the fastest and then Pb, fullscap is the
last one. I suggest using Pb first.. it is very nice and the performance
isn't bad. (At my machine, It can handle 5K req/s, 2K req/s for foolscap)..

I am not an expert on foolscap and I believe there are rooms for
improvement, moreover, foolscap provides more features in terms of security.

Regards

gelin yan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://twistedmatrix.com/pipermail/twisted-web/attachments/20120310/e91d1690/attachment.htm 


More information about the Twisted-web mailing list