UDP does not require as much resources as TCP but in the same time, it does not insure delivery of packets.
UDP is alot faster than TCP. So if its realtime obviously it has to be fast, thus UDP. The only problem is UDP isn't as reliable or as secure as TCP. But it does have the speed advantage.
UDP: DNS, TFTP, DHCP... TCP: SMTP, HTTP, HTTPS, DNS, FTP, SHH, Telnet...
In the commonly used TCP/IP communications, that would either be a TCP header, or a UDP header.In the commonly used TCP/IP communications, that would either be a TCP header, or a UDP header.In the commonly used TCP/IP communications, that would either be a TCP header, or a UDP header.In the commonly used TCP/IP communications, that would either be a TCP header, or a UDP header.
It depends on whether you want speed (UDP) or reliability (TCP).
What a client application usually selects for a TCP or UDP source port number is a random value. The value selected is generally in the range of the registered ports.
Only TCP will automatically discard a packet with a bad checksum. UDP packets have a checksum field, but it is rarely used, and then only by the application (not UDP itself)
Why_an_application_developer_might_choose_to_run_an_application_over_UDP_rather_than_TCP"send me
You can use either TCP or UDP. If you need reliable connection use TCP otherwise UDP.
UDP
UDP and TCP both are transport layer protocols. UDP is connection less and TCP is connection oriented. UDP is preferred over TCP when large amount data is to be sent like on skype or video conferencing .
**The TCP transport layer protocol uses windowing and acknowledgments for reliable transfer of data. **The TCP and UDP port numbers are used by application layer protocols. **The TCP transport layer protocol provides services to direct the data packets to their destination hosts.
TCP