blog posts

sharding

What is Sharding; A way to improve scalability

 

Before the advent of Sharding, it was thought that three characteristics could never be achieved. Decentralization”Combined” scalability “and” security “in a Chinese blockchain project. And one must always be sacrificed to the other. Together, these three features create a concept called scalability triple. First proposed by Vitalik Butrin; This concept says that if a project wants to be highly scalable. It must decentralize and then sacrifice security. And if a project intends to adhere to the decentralization feature, it must go beyond scalability.

Sharding is one of the potential solutions for Scalability. It is in the Chinese block that increases the speed and capacity of the network. It divides the computational load and data storage into smaller parts. This solution has the potential to overcome the “scalability triple” challenge, despite the significant challenges involved in its implementation.

With the birth of Sharding, it seems that the way was opened for the developers of the Chinese block to increase the scalability of their projects while maintaining security and decentralization. In this matter to help an article Collected from the block research site, we will review the history and concept of sharding and take a look at the applications of this innovation in Chinese block projects.

What is Sharding?

Simply put, sharding means dividing a large process into smaller processes; Suppose you want to complete a jigsaw puzzle of 1,000 pieces. Instead of putting all the 1,000 pieces on the table and starting to pick them up, you can separate them by the color of the pieces and then finish the job. This categorization makes it easier and faster to examine the pieces that are for a particular section.

Sharding is a solution that divides the processing load into smaller parts, thereby increasing the capacity and speed of the network. Sharding is presented as a solution that theoretically can overcome the scalability challenges of the Chinese block at the lowest cost.

The word “shard” means piece or piece, and sharding is called the cutting of a thing. To better understand the concept of sharding, we will first look at its history and then examine its role in China’s blockchain technology.

History

Sharding is not a new concept and has been used in centralized database management since the late 1990s. The term became popular when the developers of one of the first online and multiplayer role-playing games, Ultima Online, decided to distribute players on different servers to manage incoming traffic.

A common example of shading a large database in the business world is segmenting customer databases by geographic area. Customers in the same geographic locations are grouped and placed on unique servers.

Sharding in digital currencies

Given the definition of sharding and the relationship between this definition and the scalability problems of the Chinese blockchain, you have probably realized how useful this technique can be in the world of Chinese blockchain and digital currencies. In general, in the field of blockchain, sharding means dividing a data set into several parts and storing it in several databases.

Chinese blockchain networks are databases in which each node or node acts as a separate server in the network. If we run sharding in a blockchain, we are splitting the network into smaller components called “shards”. Each Shard has a unique set of smart contracts and will maintain account balances. In general, in the field of blockchain, sharding means dividing a data set into several parts and storing it in several databases.

Nodes are placed in separate shards to approve specific transactions and operations. In other words, nodes in Sharing will no longer be responsible for validating all network transactions. For a better explanation of sharding, we can use the example of the Etherum blockchain.

The Atrium blockchain is made up of thousands of computers called nodes. Each node has a certain amount of Hash power Allow the network to enable the Atrium Virtual Machine (EVM) to perform its tasks such as performing smart contracts and Decentralized applications Come on.

Etherum currently operates on a sequential or linear basis in which each node must process all operations and transactions. This is why it takes so long for transactions to go through this process. Atrium can currently process about 13 transactions per second; But for example, the visa payment system is capable of processing 24,000 transactions per second.

Sharding changes the linear execution model in which each node processes all activities to a parallel execution model in which each node is only responsible for processing a certain number of transactions. In this case, the processing of transactions will proceed in parallel and multiple lines.

A fold block is divided into different shards (subdomains or buckets). Nodes also need to run only the part of the general ledger assigned to them to verify transactions, and there is no need to maintain and update the entire transaction. That’s why the Sharding, partitioned horizontally (Horizontal Partitioning) is also known as an alternative to partition vertically (Vertical Partitioning) is.

In horizontal partitioning, different users’ data is stored at different speeds. In vertical partitioning, however, each user profile is stored on a separate screen. For example, the account balance is on one account and the wallet address is on another account.

In China’s blockchain technology, horizontal segmentation has more advantages; Because scalability can be implemented more efficiently. In horizontally segmented networks, when a larger number of users or nodes enter the network, it is easy to create a new shard to store their information; This means that as the number of users increases, so does the number of Shards, and there will be no problem with scalability.

But in vertical segmentation, the number of shards is determined and fixed based on the grouping of information. We still face the problem of scalability. In this method, some shards. Such as the shard that stores the address wallet. The intended users will eventually face the same scalability problem that ordinary blockchains face as the number of users increases.