Gabriel Genellina wrote:
En Thu, 20 Nov 2008 14:24:20 -0200, Krzysztof Retel
<[EMAIL PROTECTED]> escribió:
On Nov 20, 4:00 pm, [EMAIL PROTECTED] wrote:
On 20 Nov, 16:03, Krzysztof Retel <[EMAIL PROTECTED]>
wrote:
> I am struggling writing fast UDP server. It has to handle around 10000
> UDP packets per second. I started building that with non blocking
> socket and threads. Unfortunately my approach does not work at all.
> I wrote a simple case test: client and server. The client sends 2200
> packets within 0.137447118759 secs. The tcpdump received 2189 packets,
> which is not bad at all.
> But the server only handles 700 -- 870 packets, when it is non-
> blocking, and only 670 – 700 received with blocking sockets.
> The client and the server are working within the same local network
> and tcpdump shows pretty correct amount of packets received.
I wonder if there is a kind of setting for socket to allow no delays?
Is the program CPU-bound? If so, CPython is too slow for what you want
to do.
John Nagle
--
http://mail.python.org/mailman/listinfo/python-list