Sözlük

zkSharding

Hard

zkSharding is a re-introduced concept of Ethereum’s sharded execution layer which scales blockchains with parallelized execution within shards secured via zkEVM proofs.

What Is zkSharding? 

zkSharding is a re-introduced concept of Ethereum’s sharded execution layer which scales blockchains with parallelized execution within shards secured via zkEVM proofs. This ensures transactions are valid across different shards before being submitted to Ethereum. zkSharding introduces each individual shard as a dedicated execution layer that is fully composable with each other. 

This means a transaction can trigger the creation of new transactions on other shards, without compromising on speed or cost. zkSharding is distinct from Ethereum’s initially planned “proto-danksharding” as its implementation is more dynamic. zkSharding allows all shards to share a single validator set, split into subsets of validators dedicated to a specific shard. The subsets are reconstructed and reassigned after a certain period. 

Secondary shards post validity proofs attesting to the correctness of state transitions to the Consensus chain. The Consensus chain verifies the proofs, ensures network-wide consensus, and then posts a proof to Ethereum for verification. 

Why Does zkSharding Matter?

zkSharding is a significant step in enabling the next generation of scalable, Ethereum-native development. This serves as an alternative to Ethereum’s current modular scaling solutions that opt for app-specific rollups or L3 network architectures. zkSharding dynamically scales the network capacity with demand enabling effective, secure and composable scaling. Critically, this approach maintains a single notion of network state, which prevents fragmentation of liquidity and underlying economic security. 

zkSharding aims to address the core challenges zkRollups face. In particular, zkRollups suffer from liquidity fragmentation as outlined in the “walled garden scenario” in which multiple layer-2 (L2) environments fragment data and liquidity much like today’s internet, introducing inherent trade-offs in economic security. Fragmentation occurs when information cannot easily be transferred across different native environments. 

How Does zkSharding Work?

zkSharding is not like proto-dank sharding/danksharding, nor data-sharding. It’s more comparable to dynamic sharding where all shards share a single validator set, split into subsets of validators dedicated to a specific shard, utilizing Ethereum as its Data Availability Layer. These subsets are reconstructed and reassigned after some time to maintain the integrity of the sharding protocol. Each shard utilizes ZK proofs submitted to the Ethereum mainnet to verify the correctness of state transition. 

This also comes with the additional benefit of increasing throughput as ZKPs have a two-factor benefit of proving the correctness of state and condensing data, which frees up read/write space. These shards maintain unified liquidity and data through a cross-shard messaging protocol, eliminating any fragmentation amongst them. Developers and users alike also have direct access to Ethereum data, thanks to the Ethereum Data Provider linked to every shard.

Benefits and Tradeoffs of zkSharding

Benefits

Scalability: Fewer scalability limitations as the execution is parallel. Throughput can scale linearly with tens of thousands of transfers per second, with less than 500 nodes required. 

No Fragmentation: (a) No security/liquidity fragmentation, as each shard is a part of the whole cluster, meaning that bridges are not needed to transfer information from one environment to another. (b) Reduction of a need to migrate liquidity from Ethereum as zkSharding provides transparent access to its data for applications.

Cost: zkSharding will significantly reduce the cost of transactions relative to Ethereum, with the potential to be as low as <$0.01. 

Security: (a) State transitions secured by zkEVM compiled via zkLLVM. It provides auditable security (e.g., constraints security) as the code is easily inspectable since zkEVM circuits are compiled from a production-used EVM implementation in a high-level language and not written manually. (b) Liveness security is guaranteed with restaking existing staking pools (e.g., Lido) TVL. (c) Decentralized from day one thanks to a combination of Stake Market and Proof Market.

Trade-offs

Protocol complexity: Dynamic sharding requires more sophisticated protocol mechanics than what is typically demanded from non-sharded blockchains. The protocol must determine when to create and destroy shards that contain a particular state as a function of demand. Further, in order to enable atomicity of transactions across shards, the protocol must support high-performance networking. 

The complexity of administration: (a) A single unsharded database only requires the database server itself to be maintained. (b) In every sharded database, on top of managing the shards themselves, there are additional service nodes to maintain. (c) In cases where replication is being used, any data updates must be mirrored across each replicated node, meaning the management of this database becomes increasingly convoluted and requires high knowledge and attention.

Increased infrastructure costs: (a) Sharding by its nature requires additional validators and may need additional validator sets in the future to supplement computational power. (b) The distribution of this validator set and administration required to optimize shards effectively could lead to higher maintenance costs if not managed properly.

Auditability: (a) Whilst open-sourced zkSharding can and should perhaps be at the forefront of development, it is at the time of this writing, a highly complex topic that only a few hundred people may understand completely, making audibility of zkSharded protocols challenging.




Contributor: Misha Komarov, Co-Founder of =nil; Foundation.

Misha Komarov is the founder of =nil; Foundation, a leading developer of zero-knowledge infrastructure and Ethereum scalability solutions, such as its native circuit compiler zkLLVM, Proof Market, ‘Placeholder’, and the self-titled zkSharding rollup, =nil;. Misha is a leading developer of infrastructure for effective zero-knowledge proof (ZKP) generation. He is a researcher and developer in the fields of cryptography and database management systems (DBMS), developing vital infrastructure within zero-knowledge technology, such as =nil;’s native circuit compiler zkLLVM, Proof Market, and ‘Placeholder.’