1.2 Best-effort Datagrams (Mailed Letters)
Suppose you mail three different documents to your office on the
other side of the country on two different days. Doing so
entails the following.
- Each document travels in its own envelope.
- Each envelope contains both the sender and the
recipient address.
- Each envelope may travel a different route to its destination.
- The envelopes may arrive in a different order from the one
in which they were sent.
- One or more may get lost in the mail.
(Although, fortunately, this does not occur very often.)
- In a computer network, one or more packets
may also arrive multiple times. (This doesn't happen
with the postal system!)
The important characteristics of datagram communications, like
those of the postal system are thus:
- Delivery is “best effort;” the data may never get there.
- Each message is self-contained, including the source and
destination addresses.
- Delivery is not sequenced; packets may arrive out
of order, and/or multiple times.
- Unlike the phone system, overhead is considerably lower.
It is not necessary to set up the call first.
The price the user pays for the lower overhead of datagram communications
is exactly the lower reliability; it is often necessary for user-level
protocols that use datagram communications to add their own reliability
features on top of the basic communications.