Turning about the granularity of vertical splitting vertical sharding

Source: Internet
Author: User

The granularity of vertical slicing refers to the level of association tables that are allowed to be placed in a shard when vertical slicing is done. This problem has a great impact on application and sharding implementations.

The more association interrupts, the more the affected join operations, the greater the compromise the application makes, but the simpler the single-table routing and the smaller the association with the business, the easier it will be to use a uniform mechanism for processing. The extreme scenario in this direction is to interrupt all connections, each with a routing rule that can be handled automatically using a uniform mechanism or framework. For example, a framework such as amoeba, its routing can and can only be routed through the characteristics of SQL (such as a table ID).

Conversely, if the association interrupts less, then the join operation is limited, the application needs to make a compromise less, but the table routing will become complex, and the greater the relevance of the business, the more difficult to use the uniform mechanism processing, the need for each data request to implement a separate route. The extreme scenario in this direction is that all tables are in a shard, that is, there is no vertical slicing, so no association is interrupted. Of course this is very extreme, unless the entire database is simple and the number of tables is small.

The actual granularity of the control needs to be combined with "business tightness" and "tabular data volume" Considerations in general:

  • If the table is grouped together tightly, and the amount of data is not large, the growth rate is very slow, it is appropriate to put in a shard, do not need to do horizontal segmentation;
  • If the amount of tabular data is large and rapid growth, it is bound to the vertical segmentation on the basis of the horizontal segmentation, horizontal segmentation means that the original single shard will be subdivided into a number of smaller Shard, Each shard has a primary table (that is, a table that will be hashed with that table ID) and associated tables with multiple phases.

In a word, the granularity of vertical slicing presents the advantages and disadvantages in two opposite directions and the mutual game. What architects need to do is to balance the benefits of the project with the best of both worlds.

Turning about the granularity of vertical splitting vertical sharding

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.