The reason why we chose a NoSQL schema is that it allows for easy partitioning of tables. Let's quickly refresh our understanding of partition and learn how we will partition our tables. We will conclude this lesson by understanding how our design replicates partitions.


As the name suggests, partitioning means dividing the database or a table and storing it in multiple nodes. This concept is also known as sharding. It is important to note that partitioning can be of two types, vertical and horizontal. We will briefly revisit both types in this lesson. Then, we will discuss how we will partition our design.

The purpose of partitioning is to distribute the load of read and write requests on several nodes. There are two ways to achieve this.


Vertical partitioning is the splitting of a table by columns. The illustration below demonstrates vertical sharding.

Level up your interview prep. Join Educative to access 80+ hands-on prep courses.