As blocks are added to the rollup chain, the summaries of the transactions that exist inside these blocks are added to the main chain so all users can keep an eye on the summaries
The aggregator will take this transaction and possibly many other transactions too and produce a state update. When the aggregator gets many sufficient state updates, he put it in a block and registers the block on the rollup contract.
Merkle tree, given in the diagram above consists of the transactions received from several different users. It hashes to the universally acknowledge root “0x3217fe” which is a current state root
Rollups are based on the idea of Shadow Chain where the execution of the state is done off-chain while using the Ethereum blockchain for the data availability
here is a smart contract on the main chain (Ethereum blockchain) which maintains a state root
State root is a Merkle root (obtained from the Merkle tree) of the state of the rollup as shown in figure 3.
The Merkle tree is not stored directly inside the main chain rather only the state root is kept but the Merkle tree can be retrieved from the on-chain data.
Instead of checking the validity of every single transaction, optimistic rollup assume that all transactions and computations are correct by default until someone submits a “fraud proof” stating that the transaction is incorrect.
Any user that monitors the aggregator and detects fraud (can be an invalid state root created by an invalid transaction) can challenge an invalid update by posting the fraud proof consisting of the valid state proof and the Merkle proof.
Therefore, the waiting time of the transaction being confirmed on the main chain is longer (~7 𝑑𝑎𝑦𝑠) as compared to the zk-rollups since it can be challenged.
5. Once the fraud proof is finalized and an invalid block is confirmed, the smart contract verifies that proof and revert that block (batch) and all the blocks after that, and resume from the last non-fraudulent block. But what will happen with the aggregator?
The aggregator will be punished for submitting an invalid block. Not only the block will be reverted back to the point where the fraudulent block was posted but the bonded stake (security deposits) provided by the aggregator while posting the invalid block along with all the following blocks after the fraudulent block will also be grabbed.
optimistic rollups also have an operator called “aggregator” who accumulates a large number of transactions and publishes them to a smart contract on-chain
Glasp is a social web highlighter that people can highlight and organize quotes and thoughts from the web, and access other like-minded people’s learning.