1_20180706_Java Interview Jane said TCP / IP protocol three points

    1. Three-way handshake;
    1. Timeout Retry;
    1. Sliding window;

Three-way handshake

Pictures from the on-line "graphic TCP / IP" a book.

Three-way handshake purposes, mainly in order to enhance the success rate of network communications.

As shown:

  • The first handshake: the client sends a packet [SYNC] to the server, which is to ask the server is not able to communicate.

  • The second handshake: server after receiving the packets sent by the client, the client sends [SYN / ACK packet], used to tell the client, my side is OK,
    you can initiate a connection to me.

  • Third handshake: the client receives a return of [server SYN / ACK packet after], sent to the server again marked with [] ACK packet, meaning that
    I have here have received your letter, we communication is started it.

Timeout Retry

If after the sender sends the packet to the recipient, after a period of time (timeout), or did not receive a reply,
then the sender will think this package is lost, need to be reissued.

It should be noted that a phenomenon:

If the sender is sending three packets simultaneously, only the last received packet is confirmed, then we will consider the first two packages also receives.

Sliding window

What is the sliding window?

We can be understood as protocol transmission scheme.

Let's say the size of a transmission packet transmitting side is 3,

Sending end may send side receiving side so that it can significantly improve the efficiency of communication.

Here that size is 3, that is, the size of the sliding window.

Guess you like

Origin www.cnblogs.com/gnuzsx/p/12091448.html