Common isolation and sharing modes for business System database design

Source: Internet
Author: User

The experience of developing and maintaining certain business systems over the years has allowed people to truly understand what is known as " a well-designed database, half the success of the system", especially for multi-merchant base service platforms, public service platforms, open service platforms, or a combination of integrated service platforms. At the beginning of database design, we must investigate the isolation of the business system DB and the optimization of the sharing mode, balance the boundary of the business system, rationally design and use the necessary redundancy to adapt to the continuous change of the system, otherwise the post-developer will fall into the endless trouble and pain, which is not alarmist, Only those who have developed and maintained a platform-class product can experience it deeply. The following is a description of the most common database design isolation and sharing modes in three business systems :

I. Share database, share schema

A pattern that many developers are most familiar with, yes, it is possible that the first mis that you wrote in college was the one that was used.

Some guys think this model has little technical content, but if your business system is going to be compatible with a lot of business-side requirements, it's not easy when you choose this model, especially when the volume of business data is very large and the demand is constantly changing, and there are a variety of problems exposed.

The following analysis of the main advantages and disadvantages of this sharing mode:

1.Advantages

A. Early development is relatively easy, single-Library single-table additions and deletions, loved, attention, I said here is the earlier development easier

B. Easier read-write separation, backup and restore

C. Can maximize the use of DB server resources

C.DBA Monitoring and operations management is also very simple

2. Disadvantages

A. Late development and maintenance can be very painful, a variety of complex business sharing database, different merchant business logic differences can easily lead to development bug, especially reaching public service system

b. The capacity of library is limited, it can't adapt to the rapid growth of business data volume

C. Inconsistent multi-merchant business logic, table design-time field redundancy is unavoidable

D. Not conducive to customizing the data model, scalability is restricted

e. The business layer cannot be scaled out, and some scenarios want to get all the business logic through a single library sheet, and developers can only

Second, independent database

This is also very common, the direct understanding is for each business side independent use of their own database, non-interference. Its advantages and disadvantages are very obvious.

The main advantages and disadvantages of this standalone model are analyzed below:

1.Advantages

A. Closer contact with specific merchant business systems

b. Pre-and post-development and maintenance are easy

C. Facilitates business system splitting and integration

D. The business data of each merchant is relatively independent, and the subsystems have no influence on other merchant's business system.

E. Shunt business system data, indirectly realize the centralized data fragmentation and vertical expansion

F. Performance may be better, but may

2. Disadvantages

A. Increased hardware and software costs

b. Inevitably repeated, there is a duplication of database design and business logic, as well as an independent back-Office business support system, summed up is a sentence, duplication of labor needs more human resources input

C. DBA management pressure increases, more libraries more tables need to be monitored and operational

Third, share the database independent schema

This pattern is a design balance, with the main advantages of sharing and independent modes.

The main advantages and disadvantages of this model with shared and independent characteristics are analyzed below:

1.Advantages

A. Although is a library, but according to different merchants to split the special business, reduce the redundant database and data table design and development, cost-effective

b. Vertical scaling is easy and business splitting is easier, as long as you separate multiple merchant shares and individual merchant-specific tables.

2. Disadvantages

A. Table Design requirements are higher, to design and balance the possibility of limited expansion and unlimited expansion, or the subsequent maintenance will find it is not as easy as fully shared or completely independent mode

b. Business data set, but the table design is scattered, background system such as configuration management system, statistical analysis system is difficult to achieve the convenience of sharing mode

Summary: Above is the most common business system Database model, sharing and independence is not contradictory, each has its own specific advantages and disadvantages, they still belong to the centralized data design and management category, according to the status of the business system to select the mode. Of course, the continuous development of the late business system, the volume of data is increasingly large, the centralized data model will be a lot of problems, horizontal expansion is only a matter of time, from the perspective of database design, horizontal expansion is the eternal problem.

Common isolation and sharing modes for business System database design

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.