The purpose of layer2 design is to solve the problem of high gas on ethereum by putting some transactions off-chain, and the chain only needs to verify whether the off-chain transactions comply with the set rules. The fee spent on the chain verification is often much less than the direct execution of the transaction.
The current layer2 solutions proposed in the market are mainly sidechain, Rollup, State channels, Plasma and Validium.
As you can see from the name, a sidechain can be imagined as a chain next to the main chain. A sidechain is essentially still a separate blockchain with its own consensus mechanism. The sidechain connects itself to the main chain by bridging, locking the assets on the main chain, leaving the operations to be performed on the sidechain, and then the results are fed back to the main chain.
Since the sidechain is an independent chain, it may not be as secure as ethereum and there is some risk. Projects like xDai and Skale (SKL) are typical projects that use sidechains.
Rollup is the hottest and most mainstream 2-layer network liberation solution on the market, which has been affirmed by V. Rollup’s solution idea is to package multiple transactions into one transaction for processing, which can be understood figuratively from the meaning of rollup. In this way, the actual calculation and storage are done under the chain, and the chain only needs to record the data transaction records, which reduces the pressure of the main network’s calculation and storage, and improves the network throughput.
Rollup solutions can be subdivided into ZK rollup, Optimistic rollup and Arbitrum rollup.
Rollup solutions store transaction data on the chain, so asset security can be effectively guaranteed. However, ZK rollup and Optimistic rollup are calculated differently, as ZK rollup uses zero-knowledge proof and Optimistic rollup uses fraud proof. In short, ZK is a mathematical way to prove that the transaction complies with the rules, while OP prevents cheating through collateralization, and the collateralized assets will be forfeited if cheating is proven.
1) Zero-knowledge proof is the ability to prove that you are the rightful owner of an interest without giving away the relevant information. That is, the “knowledge” given to the outside world is “zero”.
(2) Fraud proofs: Fraud proofs present evidence that state transitions are incorrect. They reflect an optimistic view of the world: the assumption is that the block represents the correct state of the L2 data until proven otherwise. In reality, however, a committed block may contain incorrect state transitions.
One big problem with ZK rollup currently is that it is not EVM compatible, while Optimistic Rollup is largely EVM compatible, but not 100%, and Arbitrum Rollup achieves 100% compatibility.
Arbitrum Rollup and Optimistic Rollup differ in their verification of fraud proofs, with Arbitrum Rollup using multiple rounds of fraud proofs and Optimistic Rollup using a single round of fraud proofs. The main Arbitrum Rollup network is currently live, while the main Optimistic Rollup network has been delayed until July.
State channels can be considered as a relatively early layer 2 solution, which is to build a channel under the chain for transactions. This is the solution used by Liquidity Network and Celer Network.
You can think of a stateful channel as a pipe. When two (more) parties make a transaction, they need to have the same specifications of the two (more) party pipe to be able to do it, otherwise there is no way to do it. Therefore, a stateful channel is suitable for small transactions and cannot carry as much volume as an exchange, and it takes some time to set up the channel.
Validium is a new 2-layer solution that has emerged in recent years. Like ZK rollup, it uses zero-knowledge proof, but the difference is that the asset data of Validium is stored off-chain, while ZK rollup is stored on-chain. This means that Validium is less secure and is suitable for dapps that do not require as much security trust, such as games.
Plasma improves transaction speed and enables on-chain scaling by transferring transactions from the main chain to the Plasma chain through smart contracts and cryptographic validation, with the main chain only validating the block header hash submitted by the Plasma chain. plasm has low transaction costs and high throughput, but there are delays in withdrawals and no support for extending common smart contracts.
Plasma uses fraudulent proofs, and if a fraudulent proof is submitted to the root chain, the block will be rolled back and the block creator will be penalized.
The Plasma approach is used by the recently popular Horseshoe (matic), but of course Horseshoe’s ambitions go far beyond that, as they intend to be an aggregator for the entire Layer 2 network.
As the current DeFi projects are using the AMM model, the existence of infrequent losses makes some projects face a lack of depth in the liquidity pool after a late period of weakness, providing liquidity to the loss of users and the slow decline of the project. The development of a 2-tier network may lead to a new DeFi model that will become the mainstream in the future.
Attachment: 2-layer solutions and projects
Posted by:CoinYuppie，Reprinted with attribution to:https://coinyuppie.com/ethernet-layer2-summary-a-one-time-all-understanding/
Coinyuppie is an open information publishing platform, all information provided is not related to the views and positions of coinyuppie, and does not constitute any investment and financial advice. Users are expected to carefully screen and prevent risks.