[Twisted-Python] What kind of throughput can we expect to achieve when using DatagramProtocol (UDP)

Itamar Shtull-Trauring itamar at itamarst.org
Mon Mar 30 16:57:55 MDT 2009


On Mon, 2009-03-30 at 15:07 -0700, John Draper wrote:

> We have an application we intend to release where we intend to have 
> about a million applications sending UDP packets to a Twisted Python 
> server which needs to process incoming data (Approx 128 bytes of text) 
> per packet,   which a BACK end system is inserting this data into mySQL 
> tables.
>
> Right now,  in our proof of performance,  we are using UDP,  but 
> planning to move to the more reliable TCPIP protocol when we get into 
> production.
> 
> These data requests will come in fast and violent spurts of data.

In these sort of applications, batching helps a lot: less function
calls, less I/O overhead, etc.. So TCP should likely *speed* things up,
if messages come grouped in spurts. Benchmarks done with inserting one
MySQL row at a time will be far slower than batch inserts.





More information about the Twisted-Python mailing list