Distributed, clustered, and three-way handshake, is it really difficult to understand? ? ?

        The second blog, I really got up and wrote at this point! The roommates are still sleeping soundly. . . . .laughing out loudlaughing out loud

        Those who use the knowledge of radish and cabbage that are familiar to ordinary people to explain the principle of the atomic bomb are all geniuses. People who fool you with a bunch of nouns may not understand anything. Hearing this was inspiring. Recalling the radish and cabbage I encountered in my studies, and briefly summarizing some advanced computer technologies, it is a real improvement to see the sharing of these great people. Summarize yourself and share. For everyone to use in the future when they have the opportunity to pretend to be like a cow.

                                                                 

                                                                     1. Cluster and distributed explanation

 XXX restaurant, in the beginning there was only one chef named Shi Xiaoer. Shi Xiaoer is in charge of washing, choosing and cooking vegetables. The restaurant's business is booming day by day, and Shi Xiaoer is too busy in the back kitchen alone. The boss is distressed about the money and ignores the request of Chef Shi Xiaoerjia. Finally one day Shi Xiaoer strikes. (There is only one server, which cannot withstand the pressure of high concurrency, high PV, and hangs up). The boss didn't dare to dismiss Shi Xiaoer, the customers all liked his dishes. So the boss asked Xiao Er to come back and hired another chef named Shi Xiaosan. Shi Xiaosan, like Xiao Er, is responsible for washing, choosing and cooking vegetables. (Several servers have the same function to form a cluster. Shi Xiaoer and Xiaosan do the same work, and they are the cluster relationship). They are all beloved disciples of their father, Mr. Shi, and of course the dishes made by the third child are equally popular. The boss added a few sets of tables and chairs to the restaurant, and there were more guests. Little Two and Little Three can no longer cope. The boss didn't say a word, and hired another guy, Shi Xiaosi, who was in charge of washing the dishes, choosing the dishes, and helping the two chefs. This time, the two chefs can relax a lot. (The whole system is divided into different independent and interconnected sub-functions, which are published on different servers. These servers that work together to complete certain tasks are distributed relationships.)

2. Three-way handshake

        If you know about clustering and distribution, you will think of computer networks. They all rely on the network to connect and communicate with each other. Then the next popular story, let's talk about the three-way handshake. " Three times handshake (three-way handshake; three-way handshake) The so-called "three-way handshake" is to negotiate how to track the amount of data sent each time to synchronize the sending and receiving of data segments, which is determined according to the amount of data received. The number of data confirmations and when the data is sent and received, the contact is cancelled, and a virtual connection is established." ——From Baidu Encyclopedia. After reading this concept, I was at a loss anyway. In the computer network class of the conference, the teacher used the example of the Red Army and the Blue Army discussing to attack the enemy under the mountain together. I don't understand this example either. After reading an article by the great god on the public account, I have some experience.

        The restaurant is doing well. Shi Xiaoer has made a lot of money in the restaurant and wants to send it home. Suppose that money was sent by pigeons flying letters to pass books in that era (this is a bit unreasonable stick out tongue). So Xiao Er found a treasure pigeon who could fly to his hometown, and wrote "I am Xiao Er, can I receive it?". The pigeon flew to Xiao Er's house. After receiving the letter, Mrs. Xiao Er wrote "Received!" and let the pigeon fly back to the restaurant. When Xiao Er saw that she received the letter, she wrote "I know you can receive it." The note was delivered to the home. The approximate process is as follows:


The first time I send a letter, my family can know that Xiao Er can send a letter and transmit it smoothly. The second time I sent a letter, Xiao Er knew that he could send letters at home and receive them himself. For the third time, Xiao Er told his family that he could receive letters. In this way, both parties know that they can both receive and send letters, and there is no obstacle in the transmission process. In this way, Xiao Er dared to let the pigeon take the money home with confidence. This is probably the famous three-way handshake.

        The level is limited. If there are any shortcomings in the above, please give pointers.


Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324739356&siteId=291194637