Cointime

Download App
iOS & Android

Breaking Down Ethereum & Scalability: Layer 2 (L2) Sidechains

Validated Project

Ethereum is renowned for its programmability and is currently home for approximately 3000 DApps and 5000 smart contracts. Though this number calls for a big shout out, it could have been much more extensive. The dearth in blockchain such as scalability, cost and relaxed transactions are capping the DApps from choosing Ethereum. What next??

Thanks to the blockchain fanatics. Researchers in the domain have come up with various ideas to solve the scalability issue. Some straight suggestions are: changing the consensus mechanism, optimizing data storage in a block, sharding and alternatives to blockchain storage structures such as like using DAG and so on. Well, all these solutions propose changes to the underlying blockchain infrastructure and protocols. They are termed Layer 1 or L1 solutions. However, changing the fundamentals of a currently live blockchain platform is both challenging and risky. It can root to compatibility issues that may impulse forking.

But in Ethereum we do have the options to bring changes that do not affect the live blockchain layer. Ethereum has built a programmable base layer for deploying smart contracts and facilitating ether transfers. It also supports creating applications on top of this base layer, which can help improve the scalability. Such solutions are termed Layer 2 or L2.

L2 is a collective term used to denote those protocols which try to push the majority of activities “off-chain” and report to a smart contract on-chain (L1) with a summary of its off-chain activity. Since L1 is freed from intensive computations and storage requirements, it helps improve the scalability.

Working Off-chain — What is it like?

Every time a transaction happens, it should be broadcasted to all the nodes, verified by all of them and finally added in a block by a validator. The transaction will take a minimum of 12 seconds to get included in a block. If we had a smaller network with a different consensus mechanism, the transaction processing time could have been reduced.

Let us see an example.

In the Ethereum network, transactions from an account can only occur sequentially. Alice wishes to transfer some tokens to Bob, Carol, David and Elsa. She has to first transact with Bob, wait for it to be confirmed, next transact with Carol and so on. When she finishes the transactions, it will take approximately 48 seconds (assuming an optimal situation) or longer.

Imagine we have a sidechain: A minor blockchain running alongside the leading Ethereum network. It will have its consensus mechanism and an independent ledger. In this sidechain, Alice can perform the same transactions, using its native assets (let’s say TKN) at a lower cost and faster pace.

How can Alice use the sidechain to perform the transactions?

> Alice will transfer a part of her assets to the sidechain using a bridge. The bridge is a two-way peg component that allows the transfer of assets back and forth between blockchains. Just like how you transfer money from your bank account to wallet applications like Paytm, Mobikwik etc. But this may take longer.

> Alice then initiates the transfer to Bob, Carol, David and Elsa on the sidechain. The nodes in the sidechain network process these transactions. Since it’s a shorter and faster chain, the transactions happen faster.

>Occasionally, the sidechain pushes a proof, which will be a comprehensive representation of a list of L2 transactions, onto the Ethereum chain. It can be a hash of headers of sidechain blocks, a Merkle proof and so on. This will be done using a smart contract deployed on the mainchain. Anytime the state of the sidechain can be confirmed by referring to the proof on Ethereum.

Proofs are usually based on cryptographic algorithms. A simple example will be Merkle tree. A list of data items is represented using repeated hashing in a Merkle tree. The Merkle root serves as the finger print of the data set. Other techniques include Zero-knowledge proofs, polynomial commitments etc.

>The users can transact on the sidechain without informing the main chain. If the users want to transfer the funds to the main chain, they use the bridge. Since chains are independent, assets are typically locked on one chain and minted(created) on another. They are burned(destroyed) and unlocked when they are transferred back.

An off-chain process will facilitate all the interactions between sidechain and Ethereum. This process will act as an intermediary by interacting with smart contracts on both chains.

What is L2 Scaling Solutions?

The basic idea of L2 is to build a secondary framework which can handle transactions off-chain. The L2 does the transaction processing, whereas the state changes will be summarized and updated to L1. A fundamental requirement is L2 should preserve the security and risk models of L1. This also implies that, if in case, the L2 needs to be abandoned, users should be able to recover their state from L1.

Strictly speaking, the sidechain model we described cannot be counted as L2 scaling.

Let’s see the reasons.

Remember that sidechains are independent blockchains that work on their consensus mechanism and exist differently from the leading network. Nodes within the sidechain network are responsible for processing transactions, adding transactions to blocks, and maintaining consensus across the network. Note that security is the responsibility of the sidechain; it is not directly inherited from Ethereum.

Some popular sidechains are Polygon and Gnosischain.

How can L2 improve Ethereum?

L2 options offer the advantage of smaller and faster networks alongside utilizing the security and decentralization of Ethereum.

L2 applications try to reduce the workload of the main network. It will perform the major computations to itself (off-chain) and occasionally communicate with the main chain. It uses the decentralized security features offered by L1 as a guarantee. So main chain will continue to serve decentralization, security and data availability, whereas the L2 protocol will handle scalability.

State channels, Rollups, and Plasma chains are well-known L2 solutions. We will see them in the upcoming blogs.

References

[1] Cosimo Sguanci, Roberto Spatafora, Andrea Mario Vergani, “Layer 2 Blockchain Scaling: a Survey”.

[2]Gangwal, Ankit & Gangavalli, Haripriya & Thirupathi, Apoorva. (2022). A Survey of Layer-Two Blockchain Protocols.

[3]https://ethereum.org/en/layer-2/

Comments

All Comments

Recommended for you

  • U.S. Congressman Mike Flood: Looking forward to working with the next SEC Chairman to revoke the anti-crypto banking policy SAB 121

     US House of Representatives will investigate Representative Mike Flood's recent statement: "Despite widespread opposition, SAB 121 is still operating as a regulation, even though it has never gone through the normal Administrative Procedure Act process." Flood said, "I look forward to working with the next SEC chairman to revoke SAB 121. Whether Chairman Gary Gensler resigns on his own or President Trump fulfills his promise to dismiss Gensler, the new government has an excellent opportunity to usher in a new era after Gensler's departure." He added, "It's not surprising that Gensler opposed the digital asset regulatory framework passed by the House on a bipartisan basis earlier this year. 71 Democrats and House Republicans passed this common-sense framework together. Although the Democratic-led Senate rejected it, it represented a breakthrough moment for cryptocurrency and may provide information for the work of the unified Republican government when the next Congress begins in January next year."

  • Indian billionaire Adani summoned by US SEC to explain position on bribery case

    Indian billionaire Gautam Adani and his nephew, Sahil Adani, have been subpoenaed by the US Securities and Exchange Commission (SEC) to explain allegations of paying over $250 million in bribes to win solar power contracts. According to the Press Trust of India (PTI), the subpoena has been delivered to the Adani family's residence in Ahmedabad, a city in western India, and they have been given 21 days to respond. The notice, issued on November 21 by the Eastern District Court of New York, states that if the Adani family fails to respond on time, a default judgment will be made against them.

  • U.S. Congressman: SEC Commissioner Hester Peirce may become the new acting chairman of the SEC

    US Congressman French Hill revealed at the North American Blockchain Summit (NABS) that Republican SEC Commissioner Hester Peirce is "likely" to become the new acting chair of the US Securities and Exchange Commission (SEC). He noted that current chair Gary Gensler will step down on January 20, 2025, and the Republican Party will take over the SEC, with Peirce expected to succeed him.

  • Tether spokesperson: The relationship with Cantor is purely business, and the claim that Lutnick influenced regulatory actions is pure nonsense

     a spokesperson for Tether stated: "The relationship between Tether and Cantor Fitzgerald is purely a business relationship based on managing reserves. Claims that Howard Lutnick's joining the transition team in some way implies an influence on regulatory actions are baseless."

  • Are we finally ready for a gas limit increase?

    There has been growing discussion around the possibility of increasing Ethereum’s gas throughput, either by raising the gas limit or reducing slot time. The key argument in favor of this is that the hardware requirements for running a validator have steadily decreased over the past four years.

  • Cointime August 17th News Express

    1.VanEck and 21Shares Solana ETF Form 19b-4 Suspected to be Removed from CBOE Website

  • Ethereum network gas fee falls back below 1 gwei

    According to Etherscan data, the current Ethereum network gas fee has fallen below 1 gwei, currently at 0.937 gwei.

  • Cointime August 10th News Express

    1. The U.S. Internal Revenue Service has released a new draft of the crypto tax form, which no longer requires filling in wallet addresses and transaction IDs

  • Ethereum ACDC #139: Pectra's Devnet 2 upgrade is under debugging, and the release date of Devnet 3 is still to be determined

    Christine Kim, Vice President of Galaxy Research, summarized the main content of the 139th ACDC conference call. The debugging of Pectra's upgraded Devnet 2 is currently underway, and the release date of Devnet 3 is yet to be determined. Developers will hold weekly testing update meetings starting from Monday to better coordinate the release of Pectra's Devnet. The decision to include EIP-7688 in Pectra's upgrade has been postponed again.

  • Ethereum network gas fee drops to 1 gwei

    According to Ether­scan data, the current gas fee on the Ethereum network has dropped to 1 gwei.