[Twisted-Python] Need words of wisdom regarding PB

Paul G paul-lists at perforge.com
Thu Jun 29 21:25:31 EDT 2006

----- Original Message ----- 
From: <glyph at divmod.com>
To: "Twisted general discussion" <twisted-python at twistedmatrix.com>
Sent: Thursday, June 29, 2006 9:00 PM
Subject: Re: [Twisted-Python] Need words of wisdom regarding PB

> On Thu, 29 Jun 2006 20:18:14 -0400, Paul G <paul-lists at perforge.com> 
> wrote:
>>i was compressing the data before sending it over pb, while you seem to be 
>>interested in doing this automagically at the pb or transport level.
> This is, nevertheless, generally the correct way to compress data in PB. 
> PB itself is so low-overhead that compression isn't going to buy you much 
> in terms of overhead reduction, and jellying/unjellying something that is 
> already a byte sequence is a waste of time.  compress the data, transfer 
> blocks of compressed data as PB strings - the strings are incredibly low 
> overhead and length-prefixed so there isn't any real parsing overhead.

oh, i agree of course, not to mention the fact that compression (and disk 
reads, if you have any) has to be performed in a threadpool. i wasn't 
commenting on the validity of the OP's approach one way or another, since 
one usually needs to have thick skin to handle the resultant acrimony or a 
lot of free time to participate in the ensuing back-and-forth ;]


More information about the Twisted-Python mailing list