Horizontal Sharding of Database

We'll cover the following

Sharding

Data is an asset for any organization. Increasing data and concurrent read/write traffic to the data put scalability pressure on traditional databases, and as a result, the latency and throughput are affected. Tradition databases are attractive due to their property by providing the ACID guaranteed transactions.

Moreover, the relation databases can also be distributed over several computing nodes. Therefore, it is necessary to maintain the ACID-like property in a distributed fashion, which has proved very hard to extend.

One solution is to move data to a NoSQL-like system. Though the amount of historical codebase and its close cohesion with traditional databases makes it an expensive problem to tackle.

Organizations might like to scale traditional databases by using a third-party solution. But often, integrating a third-party solution has its own complexities. More importantly, there are abundant opportunities to optimize for the specific problem at hand and to get much better performance as compared to a general-purpose solution.

For using multiple machines (to divide load), we need to partition the data. Generally, we use the following ways to share the data.

  • Horizontal sharding
  • Vertical sharding

This lesson focuses on horizontal sharding, while vertical sharding is discussed in the next lesson.

Create a free account to access the full course.

By signing up, you agree to Educative's Terms of Service and Privacy Policy