Signals, sockets and message boundaries
Watch a stop signal land in the middle of an update, then see how a receiver cuts TCP bytes into records and what UDP datagrams give up. IPC and device I/O · Operating systems.
A stop signal lands while a worker is half-way through updating a record. What may the handler do, and how does a TCP receiver know where one record ends?
What you will learn
- Explain why a signal handler only sets a flag
- Cut a TCP byte stream into records with a length prefix
- Say what UDP datagrams keep and what they give up
Lesson outline
- A stop signal that arrives mid-update
- Socket scope and protocol
- Framing records over TCP
- UDP datagrams and what a send promises
15 minutes · 3 scenes · 0 predict checks · 11 quiz questions
The full lesson is available with Premium.