The Celer Network team is excited to announce that we are adding a hybrid PoS-Rollup sidechain to the Celer’s coherent layer-2 scaling platform with EVM-compatibility on Ethereum. This new addition complements Celer’s existing state channel network technology and allows Celer to offer dApp developers and users a wide range of tunable tradeoffs in terms of trust level, supported features, transaction throughput, latency and cost, all under a single unified framework. Celer’s State Guardian Network (SGN) is shared among different layer-2 technology pieces as a cornerstone to serve different crypto economics functionalities: watchtower for state channel network component, block validator for PoS side-chain component and block producer for optimistic rollup component.
Specifically for Celer’s Optimistic Rollup component, we introduce a new approach to use Celer State Guardian Network as a rollup block producer to solve the incentive design problems around tx aggregation, ordering and state storage. We have open-sourced the first-stab of our Proof-of-Concept based on Optimism’s work with additional functionalities added for this new SGN-as-block-producer architecture. With a track record of delivering production-grade software and pushing adoption via user-facing applications, we are committed to contributing to and being a part of the fast-evolving Optimistic Rollup open source community without reservation alongside other pioneering teams.
In this blog post, we review the complex tradeoffs space of existing layer-2 techniques, discuss the need for a coherent layer-2 solution and finally describe Celer’s unified framework and SGN-as-rollup-block-producer approach in a bit more detail.
Existing Techniques and Tradeoffs
At Celer we always believe that layer-2 scaling is the only way to enable Internet-scale adoption by real-world applications. We have also envisioned that individual layer-2 technology pieces need to work together as a coherent framework. Towards this goal, we have been building and delivering some of the most advanced layer-2 systems including Celer’s generalized state channel network and State Guardian Network. Now we are extending our scope beyond state channels and will complement the Celer layer-2 ecosystem with a new hybrid PoS-Rollup component. The first step of building a coherent and unified layer-2 scaling platform is to understand existing techniques and their tradeoffs.
State Channel
A state channel allows involved parties to execute a smart contract off-chain and quickly settle on the latest agreed states, with instant finality guaranteed by on-chain bond contracts. Parties involved in the off-chain transactions cooperatively maintain a multi-signature fraud-proof replicated state machine, and only resort to on-chain consensus when absolutely necessary (e.g., when channel peers disagree on a state). State Channel provides real-time interaction latency, lowest costs and horizontal scalability (whole system does not slow down as user number increases). However, it trades off the capability to support a large set of users with asynchronized interactions (e.g. NFT marketplace).
DPoS Sidechain
The core idea of DPoS sidechain is to run another distributed ledger system with independent consensus from the main chain and can bridge assets and states to and from the main chain. It provides much higher throughput compared to mainchain, similar latency and lower costs. PoS sidechain trades off main chain level security and composability to other mainchain states easily. For example, if the sidechain uses a BFT-PoS consensus, then the user should accept a security assumption that no more than ⅔ of the sidechain voting powers belong to misbehaving validators.
Optimistic Rollup
Optimistic rollup uses an entity (can be a single party or decentralized system, like in Celer, State Guardian Network) to order and batch layer-2 transactions and computes state transitions off-chain and then puts all calldata and disputable state hashes onchain. Optimistic Rollup provides higher throughput (with a limited multiplier), lower costs, full mainchain security and main-chain-like execution environment (e.g. “EVM-compatible”) with on-chain tx evaluators. Optimistic Rollup trades off transaction latency even in the optimistic case and has significantly longer latency for finality.
ZK-Rollup
ZK-Rollup is similar to Optimistic Rollup but relies on on-chain verification of ZK proof for block validity instead of on-chain disputes. ZK-rollup additionally trades off-chain computation costs to compute the proof and currently has significant limitations to generalized applications. We keep a keen eye on the evolution of ZK-Rollup but do not include it in our scope.
Plasma
Plasma is similar to Optimistic Rollup but does not have an easy solution for data availability challenges and therefore fundamentally hard to generalize and prevent the mass-exit issue. As there are many fundamental limitations, we do not consider Plasma in Celer’s unified layer-2 platform.
Celer’s Coherent Layer-2 Platform
With such a tradeoff space, it is clear that
- No single layer-2 scaling technique can handle all the use cases.
- Even a single complex real-world application may require multiple techniques to work together as a whole.
Just consider an example of an MMORPG blockchain game. When players are battling against each other, real-time interaction and 0-cost transactions for State Channel is a must to ensure smooth UX. When users are doing auctions of artifacts in NFT market places, high transaction throughput and low cost of a DPoS sidechain is ideal since not that high value is involved but the frequent transaction is needed. When users are transferring ownership of in-game real properties permanently or merging multiple high-value weapons into a rare artifact, the layer-1 security of Rollup chain is required. In addition, multiple technology pieces may work together to address a single user flow: PvP state channel battle may happen in a channel opened in DPoS sidechain to ensure fast dispute resolution if a player drops offline.
Therefore, a unified platform for dApp developers to easily leverage and deploy different underlying layer-2 scaling techniques to address complex application requirements is crucial to achieve blockchain mass adoption. Celer is extending to such a platform that supports generic EVM transaction with tunable options on different trust-level, feature, and performance tradeoffs. We call the combined construct Celer Sidechain.
Next we discuss two key designs in Celer Sidechain: 1. The novel use of Celer State Guardian Network as block producer in Celer Rollup, a sidechain with EVM-compatible optimistic rollup semantic; 2. The integration between Celer DPoS, a DPoS-based EVM sidechain, and Celer Rollup.
Optimistic Rollup with Celer State Guardian Network as Block Producer
From an architecture point of view, Optimistic Rollup sidechain has two main components: the VM execution environment and the block producer infrastructure. Different VM execution environments are on-chain anchoring points that ensure eventual security via different challenge frameworks and support generalized transactions via different “hypervisors” contract onchain. There are different flavors of VM execution environments today and we plan to contribute our engineering resources and innovation power to the most open and fast-evolving EVM-compatible execution environment.
Block producer infrastructures determine how transaction call data and state hashes are received, stored, ordered, batched and finally posts to on-chain rollup contracts. Block producer infrastructures also provide incentive structures regarding who, how and how much the users pay to use the rollup chain to execute transaction computation and to store rollup chain states. Block producer is a critical component as it largely determines the usability of rollup and barrier for mounting malicious attack attempts in optimistic cases.
Celer proposes a novel block producer infrastructure that leverages the State Guardian Network, which is as a DPoS sidechain currently functioning as “watch towers” for Celer State Channel Network, as a “logical” block producer. SGN provides the following functionalities as rollup block producer and solves several crypto-economics challenges:
- Transaction ordering. The rollup transactions are ordered by the DPoS consensus on the sidechain, therefore the rollup transactions have a consistent total order. As a result, no single validator has the power to consistently censor certain transactions. In addition, there is no need to introduce additional crypto-economics to determine the transaction ordering like in some other proposals.
- Rollup transaction fee and storage fee. Users will directly pay transaction fees in layer-2 to reward the sidechain as a whole and sidechain will internally split the transaction fee based on staking. There is no need for clients to pay the layer-1 gas fee for including their transactions in layer-2 rollup like in some other proposals.
- Producer scheduling. SGN validators are scheduled to act as rollup block producers to post transactions on-chain in accordance with the PoS consensus schedule. For each rollup block generated in SGN, there will be an order assigned to each validator to post data on-chain and if a validator misses his own posting window due to system fault or attempted censorship, the validator following him in the order can post and slash his DPoS stake directly on-chain. This posting order is very similar to the guardian assignment of the state proof dispute response process in the state channel network. As long as one validator stays non-censoring, the block will be posted on-chain with censoring party’s stake slashed and the right to propose block lost.
- Block validity challenge. SGN validators also act as monitors for all on-chain state posts. If the chosen block producer posts invalid blocks, as long as there is still one non-malicious SGN node, it can challenge the chosen one’s block proposal and slash DPoS stake directly on-chain.
- Light client state querying. Light clients will be able to query the full storage state of rollup sidechain from SGN directly without needing to compute or incur any other third-party “state storage host” to get the state and immediately after DPoS consensus is formed. This solves significant rollup UI/UX challenges where users need to wait for a very long time to get a transaction even posted (let alone confirmed) on the main chain. With Celer Rollup, users can almost immediately get “good enough” confirmation with the security guarantee of DPoS consensus. This property also significantly benefits UX when the layer-1 blockchain is congested and optimistic rollup blocks cannot be posted to layer-1 blockchain promptly.
We would like to stress that even though we use SGN as a DPoS sidechain for the above functionalities, the Celer Rollup still has full main chain security and censorship resistance even under complete DPoS consensus failure because the SGN CELR staking slashing condition is more than BFT consensus rules. As long as there is a single SGN node that is truthful, even when some validators post invalid rollup blocks on layer-1, a single truthful validator can challenge and slash the stake of SGN malicious validators beyond the normal security assumption of BFT consensus.
Even if all validators collude maliciously, it is still not “ the end of the world”. After the challenge period designated for the SGN nodes expires, an additional window will be opened for public dispute. With the very high slashing rewards, the eventual security of this construct is ensured. Finally, as we construct this as a DPoS system, the CELR holders who delegated their stake have strong incentives to ensure their selected validator will not behave maliciously by additionally monitoring the operation of SGN nodes.
When it comes to censorship resistance, SGN as a decentralized construct is naturally more censorship-resistant than single-validator constructs. Even if all validators collude to censor certain transactions, the user will have the option to initiate an on-chain censorship challenge by posting the calldata on-chain and this would require SGN block producers to either include this transaction within the challenge period or get slashed of CELR stake.
In sum, we propose the use of SGN as a decentralized block producer for optimistic rollup with clear incentive structure, main-chain security, better censorship resistance and better UX.
DPoS VM alongside Optimistic Rollup VM
As we envision that there are a lot of lower value and relatively transient transactions and application sessions that do not require main-chain-level security, we further extend the functionality of State Guardian Network to not only provide watchtower service for state channel network and block producer service for optimistic rollup sidechain but also introduce a VM execution environment on top of SGN directly to form Celer DPoS sidechain.
This comes almost for free with Celer’s coherent layer-2 architecture: we already have an EVM-compatible execution environment in SGN to maintain state storage and produce main-chain blocks for Celer Rollup. We can easily add a much faster and lower cost DPoS sidechain with EVM support by simply removing the data availability relay to the main chain.
With this additional capability, users can deposit their assets on the main chain and choose to let it appear on the Celer Sidechain either with Optimistic Rollup security guarantee or DPoS security guarantee. Users can also allow assets to migrate between Celer DPoS and Rollup.
Continue with the MMORPG game as an example: a user can deposit his in-game asset with limited value on Celer DPoS sidechain to participate in an auction market place with multiple rounds of open-bid auction. In the end, he would exit the proceeding he got from this auction session to Celer Rollup directly. With the coherent scaling platform, this asset migration and semantic change can be done with only one transaction on the main chain initiated by the DPoS block validators. The reverse-path works similarly.
In sum, the above describes how Celer Rollup works alongside Celer DPoS sidechain both riding on the staking infrastructure of State Guardian Network. Augmenting State Channel Network on either of these two semantic is as straightforward as augmenting it on the main chain so we will not discuss it in more detail.
When mainnet?
With this clear vision and significant benefits of a coherent layer-2 framework, we have started to work on an initial PoC and tentatively expect to have a Testnet version towards the end of Q1 2020. With the current scope, we expect to launch the initial version of mainnet for Celer Sidechain (including Rollup and DPoS) with EVM compatibility within Q2 2020. We are committed more than ever to bring mass adoption to blockchain technology with Celer as a strong and coherent layer-2 scaling platform!
Expect we deliver.