What is Rollup?
Last updated
Last updated
A Rollup is a network that operates in parallel with Ethereum but records transactions on the main network. Transaction validity is verified on the Ethereum network. There are two types of Rollups based on the method of transaction verification: Optimistic Rollups and ZK-Rollups.
Optimistic Rollups form batches of their transactions and record them on the mainnet in a compressed format, which makes the recording cheaper. Because transactions are not directly executed on the Ethereum network, and due to savings in the recording format, it is possible to significantly reduce gas fees and make transaction recording cheaper. In Optimistic Rollups, the recorded data on transactions is considered valid, but there is a specific period during which the recorded data can be challenged. There is a potential risk that if an invalid transaction is not contested by anyone within the allocated time, it will be recorded on the mainnet as valid.
ZK-Rollups are also networks that operate in parallel with Ethereum, but they use a different method for verifying the validity of recorded data. They also form batches of transactions, but instead of recording all transaction details on the mainnet, they submit a summary of these batches along with a cryptographic proof of the transaction's validity.
ZK-Rollups are arguably one of the most promising scaling solutions for Ethereum at the moment because, unlike Optimistic Rollups, the recorded transaction data is cryptographically verified at the time of recording. This means there is no need to wait for the end of a challenge period to ensure that the transaction will not be reversed.
However, the mathematical complexity of ZK proofs imposes certain limitations: verifying general-purpose EVM computations is a very challenging task, and active development is currently underway to address these challenges.
State channels are a technology that allows a group of participants to exchange multiple transactions among themselves while only recording two transactions on the main network: the initial and the final transaction. Here’s how it works:
In the Ethereum network, a multisig smart contract is deployed. This contract verifies that the transactions are signed by the necessary participants involved in the interaction. Participants in the state channel deposit funds into this multisig contract and then engage in off-chain interactions with one another.
At the end of their interactions, the participants sign the final outcome of their engagement. Finally, the smart contract distributes the funds according to the recorded result. This approach significantly reduces the number of transactions that need to be recorded on the Ethereum mainnet, lowering fees and increasing transaction speed while still ensuring security through the use of a multisig contract.
Plasma chain is a middle ground between rollups, where complete transaction verification occurs on Layer 1, and sidechains, which do not require such verification. The idea behind the Plasma chain is that not all transactions need to be verified by every node on the Ethereum network. Plasma chains periodically record the result of their operations along with a cryptographic proof of the current state of the network.
The actual data of this state is not recorded; instead, the proof is of a small size. As a result, the validity of the transactions themselves is not checked, but if a commitment has already been recorded on Ethereum, the Plasma chain cannot retroactively alter the transaction history. This approach helps in reducing the load on the Ethereum network while still providing a level of security through periodic commitments.
In terms of architecture, Validium is similar to ZK-Rollup solutions, with the key difference being that transaction verification data is stored off-chain. This allows for greater throughput and lower fees, but at a trade-off.
Validium solutions are less secure than ZK solutions because the operator of a Validium can potentially freeze funds without data on the Layer 1 network. While this architecture offers advantages in scalability and cost, it introduces additional risks regarding the control and access to user funds.
A Sidechain is a separate blockchain that operates independently of Ethereum but is connected to it through a two-way bridge. Unlike Rollup solutions, transaction verification is not conducted on the Layer 1 network for Sidechains.
As a result, the security of a sidechain is solely dependent on the implementation of that sidechain itself. However, this independence from the Layer 1 network provides greater flexibility in terms of architectural implementation and allows for more tailored solutions that can address specific use cases or requirements.