Technical Design Concepts Every Software Engineer MUST know | Data Streams



Request-response transport protocol over TCP is HTTP 1.0. One complete request is sent by the client, one complete response is provided by the server, and then the connection is cut off. The request methods (GET, POST, and HEAD) have particular transactional significance for server resources.

The request-response model of HTTP 1.0 is maintained in HTTP 1.1, but the connection can be kept open for additional full requests and full responses (one response per request). The connection is reused and not ended, but the request and response still contain all of their original headers. Additional request methods added to HTTP 1.1 include OPTIONS, PUT, DELETE, TRACE, and CONNECT, all of which have transaction-specific implications. But as mentioned in the Because HTTP 1.1 pipelining is not commonly used, it is far less useful for reducing latency between browsers and servers.

Long-poll: A kind of “hack” to HTTP (either 1.0 or 1.1) in which the server delays responding to the client request or just provides a partial response with headers. The client instantly submits a fresh request after receiving a reply from the server (using the same connection if over HTTP 1.1).