Вопрос

UDP is unreliable on packet level. But, doesn't it provide one response message after recieving all(supposed) packets?

I understand that TCP provide ack for all packets whereas UDP provides one response message for all packets. Am I correct?

Это было полезно?

Решение

UDP is unreliable on packet level.

The qualification is meaningless. UDP is unreliable, period.

But, Doesn't is provide one response message after recieving all(supposed) packets?

No.

I understand that TCP provide ack for all packets

No. It provides enough ACKs so the sender knows where the receiver is up to. This can be accomplished by selective ACKs.

whereas UDP provides one response message for all packets.

No.

Am I correct?

No.

UDP doesn't send any responses at all. The application must do that if required.

Другие советы

TCP connection provides reliable communication between hosts on internet. To ensure reliable communication TCP maintains state information and sequencing of packets in client and server side leading to a duplex connection. This state information is used to provide acknowledgements for received packets. There are variety of techniques of syncing and requesting lost packets according to which number of acknowledgements vary.

UDP is used where reliability is not a requirement so maintaining state information is not required leading to a more light weight protocol operation. One example of its use is streaming applications. No acknowledgement is send in UDP.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top