Seele Chief Architect Wensi Liu: Sharding is a double-edged sword. It is meaningless to simply look at the number of TPS or shards

SeeleTech
SeeleTech
Published in
5 min readDec 4, 2018

Recently, Seele team established the “Seele Frontline” media platform, in hopes to synchronize team dynamics and work progress to our global community members in real time. At the same time, Seele technical team has conducted a new round of testing on the test network. For the first round of “Seele’s front line” we’ve invited Wensi Li, the chief architect of Seele to communicate with everyone about sharding.

In reality, the problem of scaling the blockchain has always been a difficult road block to avoid during the development phase for most public chains. With the collective decline of digital currency, blockchain technology is gradually returning to rationality, the throughput problem of the public chain once again becomes the focus. The Bitcoin network can only handle 7–10 transactions per second, for Ethereum is about 20, which is much lower than the centralized payment system like Visa, which can process about 8,000 transactions per second. The low throughput problem severely restricts the development of decentralized applications based on blockchain.

On the issue of performance for the public chain, Wensi Liu gave his own opinion: “The industry is constantly trying to improve the throughput of blockchain. The main solutions are the following: sharding, sub-chain and side-chain, off-chain expansion, and different consensus mechanisms represented by PoW and DPoS, etc. Among them, sharding is considered to be an effective and ideal solution for the problem of blockchain throughput. Sharding is also one of Seele’s solution for solving the performance problems for the public chain”

Sharding: divide and conquer

Sharding comes from the divide and conquer algorithm in computer science, and it is also the classic scaling technique used in the field of traditional databases and distributed systems. The nodes in a blockchain are divided into a set of independent child nodes, and the transactions are distributed to different sets of child nodes according to certain rules for consensus confirmation. From a macro point of view, each child node set is parallel processing all the transactions of the blockchain, so the overall transaction processing performance is improved. Wensi Liu gave a simple and popular example: “We can imagine that the existing blockchain is like a busy highway. The toll booth of this highway has only one toll gate. The result of this layout is traffic jam, because people will line up waiting for only one toll station to allow them to pass through. Implementing sharding based blockchain is like adding 15 or 20 toll gates on the highway, it will greatly increases the car pass rate. Therefore, sharding will bring huge differences and significantly increases the transaction speed of blockchain.”

Sharding is a double-edged sword, Seele will be performant and safe

Regarding how to measure the performance of public chain under sharding, Wensi Liu gave some sharp answers: “There is no doubt that sharding is a sword to improve the performance of public chain, but it is also a double-edged sword. When the network is at a certain scale, the more shards, the fewer nodes will be allocated to an individual shard, and the anti-attack capability will be weakened, so that the security of the entire network will be linearly attenuated. In the world of blockchain dominated by decentralization, simply emphasizing the number or performance of shards doesn’t make much sense, it is the optimal coordination of efficiency and security that can promote the healthy development of blockchain ecology.”

Seele Chief Architect Wensi Liu (left)

There are two important issues that need to be addressed for sharding: one is cross-shard transaction, including ordinary cross-shard transfers and cross-shard contracts; the other is dynamic sharding. Each shard is like a small blockchain ecosystem, but it’s not isolated. Together they form a large, holistic blockchain ecosystem. Communication between each shard is also active that is, cross-shard transfer and cross-shard contracts, such as sending a transaction from account A in shard 1 to account B in shard 2. For dynamic sharding, a key problem to be solved is to dynamically increase or decrease the number of shards according to the number of network nodes, traffic volume and security level requirements, while ensuring user operations and various ecological applications are not affected.

As the “underlying public chain for the industry”, efficiency, security and decentralization are indispensable. Based on servers distributed in Beijing, Shanghai and Guangzhou, the Seele technical team conducted multiple rounds of TPS peak/average testing for sharded transactions, including different ratios of cross-shard transfers. The TPS test data for the eight shard are the following :

No cross-shard transaction: peak 1,500, mean 1,200; single-shard peak 200, mean 140;

Cross-shard transaction 10%, peak 1,400, mean 1,200; single shard peak 180, mean 140;

Cross-shard transaction 50%, peak 900, mean 600; single shard peak 130, mean 80;

Cross-shard transaction 80%, peak 360, mean 280; single shard peak 50, mean 35.

According to relevant industry source, the QuarkChain test network consists of 256 shards with a peak of 14,000 averaging 55 for a single shard. In the case of 8 shards, Seele has a peak of 1500 and a single shard average of 140. In the case of 50% cross-shard transaction, the peak is 900, and the average of the single-shard is 80. From the above data, Seele’s sharding performance is better from peak to average. According to Wensi Liu, the increase in the number of shards is not technically difficult, but the Seele network will not simply shard for the speed of transaction, and will also seek the optimal value in efficiency and security.

Sharding is an exciting technology in the blockchain field, it provides the hope that it could solve the scalability problem without affecting decentralization and transparency. Of course, there are still many technical difficulties that need to be overcome, but the technology has been improving and the solution will eventually mature. But perhaps the most difficult part of the technology development process is the public’s rational cognition of certain technology. When we are no longer focusing on TPS, no longer focusing on the number of shards, but can reasonably recognize the rationality of technology, then technology will not be a problem.

Bold assumptions, careful verification, and rational cognition have always been the technical creed that the Seele team adheres to.

--

--

SeeleTech
SeeleTech

Blockchain 4.0 - Seele is a blockchain ecosystem project developing a multi-chain heterogeneous forest network. Check out our official website at seele.pro