Thank you, this is a good question, and the problem is that even though the concept is very easy to understand, the details of these several different concepts are too much,
and understand the concept, to use, but also need to do a lot of research evaluation and development work. As a man who has been crawling in this field for years, I this
First introduce the concept, and then provide several open source tools and cloud services.
First of all, these architectures solve the problem, traditional databases such as MySQL (the following tools will also be MySQL-based), the problem is the single
Machine deployment, single process, so there are some problems:
Resource utilization is not flexible, it is possible that the performance of the CPU is still surplus, but the disk has been unable to read pressure or write pressure, it is possible that the disk sex
There's still a surplus, but the CPU's performance is not up to the top. It is also possible that both the CPU and the disk are redundant, but the amount of data written is too large to directly
Maximum burst disk.
Resources have the maximum limit, the CPU is used for example 64-core model, the disk up to hundreds of T, then high sorry, no more cock machine
, but there is no limit to the user's data and queries.
The upper limit of connection pool resources, why to put the connection pool alone, the reason is that the business volume of a large,
Disaster tolerance, although the transaction can ensure that the data is not lost after the restart, but the line of business to run, restart and so on.
Some of the concepts mentioned in this question are the solution to the pain points of the traditional database.
Master-slave replication (replication), to solve the problem of disaster tolerance, disaster tolerance needs to ensure the real-time database switching and data consistency,
The strength of consistency also spawned several different replication modes (asynchronous, semisynchronous, group replication)
Read Write spliting, is a business class application to solve the reading flow machine can not withstand the way, learned to name scale out
, the business of reading and writing separation classes is based on the master-slave replication.
Load balancer (balance) is also a non-database concept, but at the database level, if there is a common middle tier, that
also apply.
The relationship of these three basic can refer to these pictures:
This graph of load balance is done in the business layer, while the read-write routing logic is controlled by the business layer.
Database master-slave replication, read/write separation, load balancing, sub-table sub-Library concept