How can I be sure that UDP messages are received in order?

Answer Posted / chaitanya

You can't. What you can do is make sure that messages are processed in order by using a numbering system as mentioned in ``5.5 How can I be sure that a UDP message is received?''. If you need your messages to be received and be received in order you should really consider switching to TCP. It is unlikely that you will be able to do a better job implementing this sort of protocol than the TCP people already have, without a significant investment of time.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why sockets are used?

522


Why do we need sockets?

483


What's better 6pt or 12pt sockets?

479


What are the pros/cons of select(), non-blocking I/O and SIGIO?

977


How to find other end of unix socket connection?

512






What pieces of information make up a socket?

545


What's the difference between impact sockets and regular sockets?

474


How can I set the timeout for the connect() system call?

1107


Is a socket a file?

474


What is sae socket?

437


Are sockets files?

500


What are the types of sockets?

494


What does af mean in sockets?

520


What is the function of socket?

512


Can multiple sockets use the same port?

492