📢 Gate Square #MBG Posting Challenge# is Live— Post for MBG Rewards!
Want a share of 1,000 MBG? Get involved now—show your insights and real participation to become an MBG promoter!
💰 20 top posts will each win 50 MBG!
How to Participate:
1️⃣ Research the MBG project
Share your in-depth views on MBG’s fundamentals, community governance, development goals, and tokenomics, etc.
2️⃣ Join and share your real experience
Take part in MBG activities (CandyDrop, Launchpool, or spot trading), and post your screenshots, earnings, or step-by-step tutorials. Content can include profits, beginner-friendl
From on-chain to off-chain: state channels and Roll-ups
Author: Bill Buchanan, Source: Medium, Translated by: Shaw Jinse Caijing
Soon after, we need to realize that we are operating within a traditional financial world and need to build a more trustworthy digital infrastructure. In fact, the transformation we require is not limited to the financial sector, but extends to any area that demands high levels of trust, security, and distribution. For this, we can adopt Layer 1 blockchain approaches like Ethereum, but it has already exposed scalability issues, as its main ledger and computational infrastructure cannot handle more than 15 to 30 transactions per second. However, new methods are being adopted today to alleviate the burden on Ethereum—while still maintaining its credibility and distribution. These methods include shared Layer 1 implementations and the transition to Proof of Stake (PoS). However, the most concerning advancements are occurring in Layer 2 methods, which are built on top of the core Ethereum network (mainnet).
Layer 2: State Channels
State channels were originally implemented in the Bitcoin Lightning Network and were later extended to Ethereum. In this way, we basically have two records on the mainnet ledger, where the parties involved must commit some funds that may or may not be used. For example, suppose Bob wants to create a side channel to pay customer fees and commits to paying 10 ETH. He will then create a channel contract. The committed ETH will be locked during the validity period of the channel and cannot be used. Bob can give Alice 2 ETH and Carol 3 ETH. Once completed, he will submit the finalized transaction, and Bob will recover 5 ETH, while Alice and Carol will receive 2 ETH and 3 ETH, respectively. Finally, Bob only needs to publish the summary data and only pays transaction fees for the two commitments on the mainnet ledger. The implementation of state channels is provided by Polygon, which achieves full EVM compatibility and low transaction fees. Here is an example:
Layer 2: Roll-ups
One of the best mechanisms to scale Ethereum is to move transactions off-chain through Roll-ups and sidechains.
Optimistic Roll-ups
These mechanisms process transactions off-chain and assume that the transactions are valid (essentially a "trust but verify" approach). They only consume computational resources on the mainnet when there is a dispute over the transaction. Therefore, there is a delay of a "challenge period" before a transaction is truly confirmed on the mainnet.
In Arbitrum, fraud observers analyze transactions, and if fraudulent transactions are detected, the observers will publish the fraud proof to the mainnet. In practice, Arbitrum can identify the lines of code related to fraud analysis and then publish them to the mainnet. The mainnet can then adjudicate the fraud proof and decide whether to execute the required code. Arbitrum has a seven-day withdrawal period.
Zero-Knowledge Roll-ups (zk-Rollups)
These technologies move computation and state storage off-chain and adopt a trustless approach. Once the state is updated back to the mainnet, only minimal updates are required to complete state changes and their related proofs. Because we have proofs in a compressed format, we can quickly verify updated transactions while ensuring the privacy of the transactions. With this technology, unlike Optimistic Rollups that take days to submit, using zk-Rollups (based on zkSnarks), we only need about an hour to verify the proofs. This ensures that there is no double spending, and all transactions are solvent. ZKsync is an example.
sidechain
This is an independent sidechain, which is a separate blockchain connected to the mainnet. Unlike the roll-up method, updated transactions can be echoed back to the mainnet when needed. Overall, they have their own blockchain and consensus mechanism, such as Proof of Authority (PoA). Polygon is an example of a sidechain infrastructure. The overall weakness of sidechains is that their security model may differ from that of the Ethereum mainnet.
Conclusion
In my opinion, using zero-knowledge proofs in offline chains is the best solution, as it allows for quick verification of transactions on the main chain while protecting the privacy of both parties involved. We can also use selective disclosure in zero-knowledge proofs, which is useful for revealing important information, such as whether a person is authorized to access a certain resource.
For Optimistic Rollups, we assume transactions are valid unless there is contrary proof, and a challenge period is required during which transactions can be contested before finalization. In contrast, with zk-Rollups, our transactions are valid because there is associated proof, and they can be quickly submitted to the mainnet. Unfortunately, zk-Rollups require a deep understanding of cryptography and blockchain, which may slow down the development process.
Clearly, Ethereum is not the only option; alternatives like Polygon, Solana, Cardano, and Polkadot offer more scalable solutions than Ethereum. However, we love this blockchain that brought us smart contracts and the Ethereum Virtual Machine (EVM), and many hope it can overcome scalability issues while maintaining the same level of decentralization and security.