[JDEV] UDP vs TCP

Thomas Charron tcharron at ductape.net
Fri Sep 1 11:43:44 CDT 2000


Quoting Benjamin Kahn <xkahn at cybersites.com>:
> 	The advantages of UDP are:
> 	Lower overhead.

  Yep, that's it.  The basic argument is, a little less overhead per 
connection, of many, means many more connections supported on larger machines..

> 	Umm...  Anything else?

  That's it.

> 	Honestly, you can make a fairly decent IM system with
> UDP.  Messages can't be > 64k.  (Unless you are willing to play
> fragmentation games with the packets.)  Messages may get lost, but that
> might be okay.  Only a few people really care about security
> ANYWAY.  Messages may come out of order, but that probably doesn't matter
> in this case.  And presence can be determined by pinging.  (Ping every 5
> seconds,  If the server hasn't heard from you in 12 seconds, you're
> offline.)  

  This is how IP determines to close a logical TCP socket.  It's just 
transparent to you.

> 	But why are we discussing this?  Jabber is quite firmly TCP at
> this point.  It would be a MAJOR overhaul to change, and the benefits
> just aren't really there.  

  Actually, as I said before, it really isn't.  Adding mod_udp can extend 
protocol support, just as mod_http does.  Hell, I could add protocol support 
for messages being delivered via SMTP messages, carrying an XML payload  
(ICKICKICK..  Just a DRASTIC example).

  Basically, if someone wants to do it, go ahead..  ;-P
--- 
Thomas Charron
<< Wanted: One decent sig >>
<< Preferably litle used  >>
<< and stored in garage.  ?>>




More information about the JDev mailing list