[Twisted-Python] dataReveived() buffer best practice?

Phil Mayers p.mayers at imperial.ac.uk
Wed Oct 12 05:29:35 EDT 2011

On 10/09/2011 12:56 AM, Glyph wrote:

> Since this is your day job - is there a formally-correct name for
> this phenomenon?  I usually refer to it as "packet fragmentation"
> even though I know that's not really it - as you say, IP
> fragmentation doesn't really happen. It's not like it's really TCP
> re-segmenting either, because one send() is not necessarily one
> segment.

Sorry, only just got round to replying...

Sadly there's no consistent name. The vendors all call it different 
things and implement it in subtly different (occasionally broken...) 
ways, and either hotly deny or proudly proclaim they're doing it, 
depending on which single basket they've put all their eggs in... ;o)

e.g. F5 make a big thing of the fact that their load balancers do local 
termination of TCP (and other) protocols, allowing them to do things 
like multiplex N client connections into M (fewer) server connections, 
while still optionally preserving client ip/port and server ip/port - 
although F5 do also have non-terminating "fast" per-packet modes.

It's variously called TCP termination, proxy and normalization. Some 
vendors use "layer 4" instead of TCP. Some incorrectly use "layer 5" or 
"layer 7" to describe their own idea of what is happening.

In my experience it is usually load-balancers that do this, although 
if/when NAT64 takes off, we may see a lot more of it, depending on 
whether vendors choose to terminate the TCP connection, or munge the MTU 
discovery / MSS options to match the payload sizes on the IPv6/IPv4 legs.

Ordinary NAT boxes tend to use a fast per-packet rewrite, rather than 
buffer TCP content.


More information about the Twisted-Python mailing list