Clusters, distributed understand

Long before the software or desktop software is a stand-alone, the game mostly stand-alone game. Later, technology development, with the network, the Internet more and more people, and thus it is difficult to a computer to complete the requested service so much. So according to the object-oriented thinking, in addition to refining solution is clustered, or distributed deployment from real life.

Clusters: life scene is in the form of contractors led by a group of farmers, each request you initiated the need for contractors, sub-contractors will task to name the following agricultural workers. This work has a name so that each farmer thing, which is load balancing (labor contractor to do is load balancing). Tomcat common is the combination of nginx, nginx do load balancing requests forwarded to one of the following lot tomcat, in which a server is down does not affect the whole system, but will increase the load to other servers.
Distributed: is a complete system to split into several subsystems to co-processing subsystem can perform a particular function, one of the subsystems is down, then it is responsible for a particular business would not be complete.
But no matter what software will read and write access to the database, the database access related to disk IO, the efficiency of natural relatively low, some basic data is read 99 times, once to write. If every time access to the database, the database represents a lot of pressure, so there is a cache is to store data into memory, the memory speed is many times hard to improve the efficiency, common is memcached and redis. If the data is relatively small, java hashmap can be when the memory cache some data

Guess you like

Origin www.cnblogs.com/zeevy/p/12118152.html
Recommended