Any difference between socket connection and tcp connection?

后端 未结 4 1678
南方客
南方客 2021-01-31 10:59

Are these 2 concepts refer to the same thing? Do they have difference?

In my opinion, they are different, and socket connection is based on tcp connection. A socket cont

4条回答
  •  离开以前
    2021-01-31 11:26

    Socket is layer 5 protocol (Session) in OSI Model and is not dependent on underlying layers which means it can be over TCP, UDP, MPTCP, ... (Layer 4 - Transport layer protocols). Socket connection is used for continues exchange of data between nodes (it creates a session between them) but TCP connection makes a reliable transmission of data segments between nodes.

提交回复
热议问题