以太坊Vitalik发布关于sharding的部分概念验证

以太坊创始人Vitalik Buterin于昨日在twitter上发文”sharding is coming“,同时在reddit上发表了一片稍长的文章。文中描述了一种基于”fork choice rules“的概念,评论中有人觉得文章晦涩难懂,并问beacon链是什么?关于sharding,可以先阅读以太坊sharding一文做一了解。

我个人对文中提到的beacon链的理解是过度链,在sharding前三阶段与主链并存用来测试PoS切换。文中提到,在第四阶段,beacon链会整合到以太坊主链中。所以,文中出现的beacon链可以理解为暂时性的基于PoS的以太坊主链。其它内容较易理解,Vitalik在reddit上原文如下:

This is a proof of concept of (part of) a fork choice rule-based mechanism for how sharding can be bolted on top of the current ethereum main chain, with a specialized random beacon and shard block times of <10 seconds. The basic idea is based on a concept of dependent fork choice rules. First, there is a proof of stake beacon chain (in phase 4, aka full casper, this will just be merged into the main chain), which is tied to the main chain; every beacon chain block must specify a recent main chain block, and that beacon chain block being part of the canonical chain is conditional on the referenced main chain block being part of the canonical main chain.

The beacon chain issues new blocks every ~2-8 seconds, with a design similar to the one prototyped here (implementation at https://github.com/ethereum/research/tree/master/old_casper_poc3), using the RANDAO mechanism to generate randomness (see https://ethresear.ch/t/rng-exploitability-analysis-assuming-pure-randao-based-main-chain/1825https://ethresear.ch/t/rng-exploitability-analysis-assuming-pure-randao-based-main-chain/1825/10 and http://vitalik.ca/files/randomness.html for analysis), and its purpose is to be the “heartbeat” for the shard chains and to provide the randomness that determines who the proposers and notaries in the shard chains are. The beacon mechanism is upgraded with a proof of activity-inspired technique to increase its stability.

The shards then themselves have a dependent fork choice rule mechanism that ties into the beacon chain; every time a new beacon block is created, that beacon block randomly selects a proposer which has the right to create a shard collation. Each shard collation points to a parent collation on the same shard, and a beacon block.

Things that are not included in this test are:

  • The mechanism for notaries to confirm shard collations (though this is trivial to implement; it’s the same as for beacon blocks)
  • The shard-to-main-chain crosslink (see https://ethresear.ch/t/cross-links-between-main-chain-and-shards/1860) that ties the beacon and the shard chains back into the main chain
  • The feature where all notarizations of any shard simultaneously double as votes in a global Casper FFG cycle, increasing Casper FFG scalability and allowing its min deposits and finality times to both be reduced (perhaps min deposits to 32 ETH and finality times to ~6 minutes)

Vitalik在Reddit上发表的原文链接:https://www.reddit.com/r/ethereum/comments/8g1q55/vitalik_teases_sharding_release_on_twitter/dy85pq0/