Irontech
Links: https://www.zhihu.com/question/20085992/answer/71742030
Source: Know
Copyright belongs to the author, please contact the author for authorization.
The following explanation is copy from Quora, and the answer is wonderful.
HTTP uses TCP connection. But the HTTP uses only one TCP connection.
In HTTP, client initiates an HTTP session by opening a TCP connection to the HTTP server with which it wishes to Communica Te. It then sends request messages to the server, each of which specifies a particular type of action that the user of the HTT P client would like the server to take. The server responds to the client's request and sends the data which he wants. But the HTTP uses only one TCP connection i.e. from client to server, the there is no TCP connection from the server to the client. The server sends data to client there was no guarantee that the client was going to get it. If client does not get the data in the TTL (Time to live), it again make a request for the data.
We need a reliable connection from client to server so that server can get all the requests made by the client. There is no need of reliable connection from server to client. If client doesn ' t get the data what he requests in the time, he again makes requests for the data.
TCP for HTTP protocol but only one-way connection is established