Skip to main content

Command Palette

Search for a command to run...

Optimism In Ethereum Blockchain Network

Published
5 min read
Optimism In Ethereum Blockchain Network
F

I am a AI/ML engineer and a Web3 technical writer who loves to educate developers and crypto users. I work with AI and Web3 protocols to update their technical content marketing game!

Due to the massive influx of crypto users, ethereum as one of the major networks has been confronted with the issue of scalability and a very high rate of network congestion.

The cost of making transactions on the ecosystem has become very expensive. During the recent Otherside sale, gas fee rose to a staggering amount of 8,000 gwei, this means that individuals who were willing to make transactions would pay an exorbitant price of 2 ether.

This poses a huge block to the future of transactions on the ethereum network. This article will provide a brief and lucid explanation on how to avoid huge gas fees through the use of layer2 scalability and most importantly, optimistic rollups.

Optimistic rollups and their interaction with Ethereum

Layer2 protocols offer off-chain scaling solutions, designed to operate above the ethereum network system. These protocols are activated, monitored and controlled by smart contracts present in layer1.

Optimistic rollups process transactions off the ethereum network off-chain and post off-chain transactions in bunches to an on-chain rollup contract. It is immutable.

Structure of optimistic rollups

On-chain contracts: There are smart contracts present in the ethereum network, these contracts serve as the power-house to the layer2 protocol. They control the rollup blocks, monitor state updates and keep track of the Users’ deposits.

Off-chain virtual machine: Although the controlling smart contracts are made on the ethereum the effects, computations and storage are made on another virtual machine before it would be finally transported to the on-chain network for total submission.

In the simplest words, off-chain activities can be likened to an over-head bridge (layer2){optimistic rollups}, relieving the original road (layer1){ethereum mainnet} of traffic congestions.

How does layer2 work?

Users send their transactions to the Operator or Validator, who then compresses these transactions and sends them in bundles to the ethereum mainnet for final validations.

Becoming a Validator in layer2 is almost the same with the procedures in layer1, following the proof-of-stake. A Validator must stake a certain amount before he/she can become a certified Validator.

When a validator is dishonest, commits an error or stacks his/her transactions on an old but erroneous code, the bond staked by such Validator is slashed and burned. This staking system prevents fraud and works just like the proof-of-stake system.

Fraud proving system

The layer2 network allows anyone to send blocks without providing a means of validity unlike ZKsync, however, to maintain the security of the network and to prevent fraudulent practices, blocks/blobs are subject to what is called challenge window.

This is a period of time in which the intended transactions now referred to as assertions are open to being challenged by other nodes on the network.

When a transaction or series of blocks are challenged, the system opens a fraud-proof process, where they are verified by the layer1 itself and when the transactions are truly found to have been dubious, erroneous or consists of discrepancies, the Validator would be penalised by having his bond slashed.

Furthermore, to prevent bad actors from spamming every transaction with a challenge, the Challenger will also stake some bonds, when the challenge has been reviewed and found to be a false alarm, part of the bonds of the Challenger is slashed.

Every fraud-proof process is interactive as there has to be an assertion before there can exist a challenge.

However, this system of checks-and-balances does not come without a price. During the period of the challenge window, challenged transactions will be reviewed and redeployed several times thereby incurring additional gas fees.

In view of this, the Ethereum mainnet has brought up a system of multi-round fraud proving.

This system involves a process whereby an arbitration is conducted by layer1, the layer1 Arbiter will try to detect the lying party by asking the Challenged to provide the one-step proof.

If the Challenged is not able to provide or what that he/she provided is not considered to be valid, the transactions will be reconducted and the bonds of the Validator will be slashed as a penalty.

Multi-round fraud proving is more gas efficient.

Types of optimistic rollups and how they operate

Firstly, optimism is the first of the rollups and it uses a single-round fraud proof process. Once a transaction is validated in optimism, it will not undergo any other test when it gets to the ethereum network. However, a defect of optimism is that it incurs an additional gas fee.

Moving forward, we have Arbitrum as the optimistic rollups. Having noticed the defect of optimism, arbitrum tweaked the source code of optimism and made use of a multi-round fraud proof process. This solves the problem of additional gas fees.

Lastly, there is Metis, which has more features. It provides swift and highly decentralised services. Metis uses multiple sequencers as opposed to one, it has its virtual machine, called the Metis Virtual Machine. It also has its own token called MetisDao.

Advantages of optimistic rollups

Here are some advantages of optimistic rollups:

(1). The system offers an alternative to the congested ethereum mainnet, this provides a more gas-efficient means.

(2). Offers scalability without sacrificing trust and security

(3). It provides a system of checks and balances; to prevent fraud and malicious reporting.

(4). It ensures that every node in the ecosystem has access to the fraud-proof unlike ZKsync that requires special hardwares.

(5). It takes at least only one honest node to dismantle the fradulent practices of dishonest nodes

(6). It relies on a well-designed cryptographic incentive system to increase security on the network.

(7). Compatibility with EVM and solidity allows for the easy creation of DAPPS and reusing of old tools.

Demerits of optimistic rollups

Here are some of its downsides:

(1). There is delay in transaction finality due to potential fraud challenges.

(2). It is not decentralised, the transactions are under one authority i.e The Validator.

(3). Funds in the network will be severely plundered if there is no single honest node

(4). Users must wait for the challenge window to be over (one week) before withdrawing their money to the ethereum mainnet

(5). Rollups must enter all transactions, this will certainly increase gas cost.

Key takeaways

  • Due to the ever increasing population of crypto users, there is a need for decongestion and we do this using layer2 scalability

  • There are two types of layer2 and they are Optimistic rollups and zero-knowledge rollups

  • There are three types of optimistic rollups and they are optimism, arbitrum (most popular) and Metis

  • The use of layer2 scalability apps reduce gas fees sporadically.

More from this blog

Joshua's Web3 Blog

7 posts