Rollups: The Holy Grail of Ethereum Scaling
Published on: March 28, 2023 Last Updated: June 29, 2024

Rollups: The Holy Grail of Ethereum Scaling

Why does Ethereum need Layer 2 (L2) scaling?

It all comes down to something known as the “blockchain trilemma.” The trilemma stipulates that out of the three properties that blockchains aim to achieve-security, decentralization, and scalability-only two can be achieved simultaneously within the Layer 1 (L1) network.

The two largest blockchains, Bitcoin and Ethereum, have historically prioritized security and decentralization over scalability, leading to the advent of L2s that aim to bring the missing scalability component to L1. Because Ethereum already houses a thriving ecosystem of L2s, we’ll focus on Ethereum here. We’ll zero in specifically on rollups, which have proven to be the most effective L2 method for scaling Ethereum.

The transaction bottleneck

To understand how rollups scale Ethereum, it’s first important to understand the scalability challenge at hand. As the number of people using Ethereum rises, the network becomes more congested, which results in transactions becoming slower and more expensive. This dynamic stunts Ethereum adoption and the development of applications that need to handle a substantially higher volume of transactions and at low fees.

To put this into perspective, Ethereum mainnet processes a mere 13 transactions per second (TPS), while Visa averages 1,700 TPS. So how can Ethereum scale to support such applications ranging from payments to onchain gaming and decentralized finance (DeFi)?

Simply raising the number of transactions per block on Ethereum would make the network less decentralized, because it would become more expensive for people to run Ethereum nodes (independent copies of the Ethereum transaction history).

Additionally, very large block sizes can destabilize consensus because they are harder to process, slower to propagate, and require more bandwidth. This can cause some nodes to fall behind, leading to consensus failures and temporary forks. To address these challenges, scaling solutions called rollups have emerged.

What are rollups?

A rollup is a Layer 2 scaling solution that offloads the heavy computation associated with transaction execution from the more expensive L1 (usually Ethereum), while storing minimal transaction data on the Ethereum mainnet. Rollups make transactions dramatically faster and cheaper while still benefiting from Ethereum’s decentralized security model.

How rollups work

At the core of a rollup is a smart contract deployed on Ethereum, which maintains the state root of the rollup-meaning the entire state of the rollup, including account balances, contract code, and storage. When a user transacts on an L2 rollup, what’s happening behind the scenes is they send their transaction to the rollup contract, which then processes the transaction on L2.

Rollup operators collect multiple transactions on L2, execute them, and generate a new state root based on the resulting state after the transactions have been processed. They then compress the transactions into an efficient format and submit them as a batch to the mainnet contract, along with the previous state root and the new state root. If they match, the contract updates its state root to the new one provided by the rollup operator.

Because rollups move the heavy computation associated with transaction execution off the L2 and process multiple transactions at once, they offer much faster and cheaper transactions than transactions executed directly on L1.

Types of rollups

A crucial component in rollup technology is how they ensure that the state differences submitted by the operators are correct and that no invalid transactions are included in the batches. Rollups address this challenge through two distinct approaches:

  • Optimistic rollups: Optimistic rollups operate under the assumption that all transactions submitted to L1 are valid by default. To prevent fraud, they incorporate a dispute-resolution mechanism that allows anyone to challenge the transaction in question within a certain time frame (typically a week) by submitting something known as a “fraud proof“, which proves that the state transition was incorrect.
  • Validity rollups: Validity rollups, on the other hand, require the operator to submit a cryptographic proof attesting to the validity of every transaction in the batch along with the batch itself.

While optimistic rollups count on the integrity of network participants-in other words, people-to catch and challenge fraudulent transactions, validity rollups rely on math and are therefore inherently more secure. In addition, because validity rollups don’t require a challenge period, they offer much faster finality on L1, whereas optimistic rollups that use fraud proofs require up to a week for L1 finality.

The future of rollups on Ethereum

Rollups are already enabling use cases that wouldn’t be possible on Ethereum otherwise. For instance, Starknet, a validity rollup that uses STARK proofs to scale Ethereum, supports a wide variety of applications requiring enhanced throughput, from derivatives-trading platforms like Paradex to onchain-gaming engines like Dojo.

Although most rollups are still in their early stages, they offer several benefits that make them essential for Ethereum’s scalability and success once fully developed:

  • Enhanced throughput: Rollups provide higher throughput compared to L1 blockchains, unless the L1 is centralized, which is not the case for Ethereum. Regardless, centralization is an undesirable attribute for blockchains.
  • Seamless composability: All validity rollups settling on Ethereum will ultimately become seamlessly and atomically composable, enabling efficient interaction between dApps.
  • Inherited security: Rollups inherit their security from the settlement layer, so the ideal rollup will be as secure as Ethereum itself.
  • General-purpose functionality: Rollups are fully general-purpose, and one can even run an EVM inside a rollup, such as Kakarot on Starknet. This feature allows existing Ethereum applications to migrate to rollups with minimal need for writing new code.

To conclude

Rollups are changing the landscape of Ethereum’s quest to overcome the blockchain trilemma, introducing a way to improve scalability while inheriting the base layer’s security and decentralization.

A centerpiece of Ethereum’s roadmap since 2020, rollups make transactions faster and cheaper by moving the computational heavy lifting to L2. This scalability makes use cases that require speed and low costs, such as onchain gaming and high-speed DeFi trading, economically feasible on Ethereum. As rollups continue to transform Ethereum, they not only address the blockchain trilemma, but also pave the way for a more inclusive, efficient, and expansive decentralized world.

ON THIS PAGE

Contact us