I know that UDP doesn’t always receive packets in order or at all, but how can i find out why? Is it that the packets get lost or reordered in the transport. eg different packets take different routes and arrive at different times. or is it that corrupt packets get resent and thus arrive later?
I would prefer if this could be answered in post, but if you could redirect me to a better source that would also be appreciated.
For purposes of speed and efficiency packets aren’t received in order, meaning any packet can take any route and doesn’t have to wait for any other packet to have arrived/sent. Because reliability is not one of the main concerns of UDP, it doesn’t care.
Dropped packets are also not resent because no checking is being done at either end. UDP is mostly used for things were loss of a few packets is not that relevant, such as streaming media, VoIP etc.
If you want reliability then you need to use TCP.