reconnection
Re-establishing a dropped long-lived connection and, where supported, resuming from the last message received.
In more detail
Networks change, devices sleep and servers deploy, so connections fail normally. Reconnect with bounded backoff, resume from a sequence number or event identifier, expect duplicates, and authenticate again.
Related terms
- backoff — Waiting longer and longer between successive retries, often doubling the delay each time, so a struggling service has room to recover.
- sequence number — An increasing number attached to each message so the receiver can detect gaps, reorder messages and say where to resume.
- Last-Event-ID — The header a Server-Sent Events client sends when reconnecting, carrying the id of the last event it received so the server can continue from there.
- WebSocket — A protocol that turns an HTTP connection into a long-lived, two-way channel where client and server can each send messages at any time.
Taught in
- WebSockets — Modern API Architecture: REST, GraphQL & gRPC
- Server-Sent Events — Modern API Architecture: REST, GraphQL & gRPC