Re: UDP server socket

From: Peter L Hansen (peter_at_engcorp.com)
Date: 10/14/04


Date: Thu, 14 Oct 2004 09:03:34 -0400

Ajay wrote:
> whats the maximum number of datagrams that can queue up on a UDP server
> socket? or is that system dependent?
> i have some code that iteratively handles datagrams, and while testing it,
> i noticed that it responds to at most 3 datagrams (i tried sending 4, 6, 8
> and 10 datagrams / second)
> is that a system dependent feature or can i change that (i didn't see
> anything in the manual)

I don't believe (though I'm not an expert in UDP) that you can
"queue up" UDP packets at all. At least, there are explicitly
NO guarantees as to whether any given packet will even make it
through the network, and I doubt any system provides explicit
guarantees as to how many UDP packets can be handled if there
is a backlog. If you are looking for reliable communications,
that's what TCP is for... otherwise you have to handle missed
or duplicated packets yourself.

-Peter



Relevant Pages

  • Re: 1000s UDP packets arrive same time problem
    ... UDP receive thread ... queue processing thread ... when receive UDP packet: instantiate new data object; ... > It sounds like you need to be able to offload packages from the OS as fast ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: tcludp - bug when closing 1-of-2 listening ports
    ... I'd say something like a zero-length UDP packet... ... It is indeed linked with zero-sized UDP packets. ... % puts -nonewline $s titi ... The zero-sized packet wreaks havoc in tcludp only if it comes on ...
    (comp.lang.tcl)
  • Re: Deaf CAsyncSocket on Windows Service.
    ... Note that for UDP, your network stack is free to discard, at any time, for any reason ... correlation between UDP packets sent and UDP packets received, ... UDP does not guarantee delivery, ... If you do a receive of fewer bytes than the UDP message, ...
    (microsoft.public.vc.mfc)
  • Re: receive delay
    ... UDP packets are used for new mail notifications, or in this case to notify ... the client is requesting the update instead of the server sending a UDP ... right of outlook, also under E-mail accounts the Use Cached mode is ... Something is blocking UDP packets. ...
    (microsoft.public.exchange.admin)
  • blocking for multiple sources
    ... One of my other threads' job is to queue up UDP packets for the main ... But occasionally I may need to have the main thread send a pulse to the ... with a timeout using select, ...
    (comp.os.qnx)