📢 #Gate Square Writing Contest Phase 3# is officially kicks off!
🎮 This round focuses on: Yooldo Games (ESPORTS)
✍️ Share your unique insights and join promotional interactions. To be eligible for any reward, you must also participate in Gate’s Phase 286 Launchpool, CandyDrop, or Alpha activities!
💡 Content creation + airdrop participation = double points. You could be the grand prize winner!
💰Total prize pool: 4,464 $ESPORTS
🏆 First Prize (1 winner): 964 tokens
🥈 Second Prize (5 winners): 400 tokens each
🥉 Third Prize (10 winners): 150 tokens each
🚀 How to participate:
1️⃣ Publish an
Layer2 Sorter: Principles, Current Status and Future Development Trends
The Principles, Current Status, and Future Development of Sorters
The main source of income for Layer 2 is the Gas fees paid by users during transactions. After deducting the costs of submitting data to Layer 1, the remaining part is basically pure profit. According to statistics, the profit of OP Mainnet in the second half of 2023 was approximately $5.23 million, Arbitrum's annual profit was $16.5 million, and zkSync Era's profit from March to December reached $22.24 million.
These huge profits are closely related to the operation of the sorter. So, what is a sorter? How does it work in Layer 2? What problems do centralized sorters face? How will sorters develop in the future? This article will delve into these questions.
Principle of Sorters
The sorter plays a key role in Layer 2, primarily responsible for receiving user transactions and executing them, then submitting the sorted and compressed batch to Layer 1.
Layer 2 can be compared to Ethereum's public transportation system, where the sequencer is like a bus driver. The driver tells everyone that there's no need to drive into the city personally; as long as they pay a service fee that is lower than the cost of driving themselves, they can reach their destination, saving both money and effort. To maximize the use of space inside the vehicle, the driver will try to fill up the passengers as much as possible before departing and will rearrange the passengers to make the vehicle "fit snugly."
( Who can run the sorter?
Common solutions include:
Centralized Sorter: Run directly by the Layer2 team or designated organizations, it is cost-effective and efficient, making it the team's preferred solution.
Fully Permissionless Sorter: Anyone can sort and submit to Layer 1. However, this scheme, while seemingly fair, has obvious drawbacks. Sorters are different from Layer 1 miners or validators; they do not enhance final security but merely submit batches. When multiple participants submit simultaneously, only one is ultimately included, resulting in a significant waste of resources.
What is the sorting standard for )?
There are usually two ways:
First come, first served: Similar to taking a seat on a bus, transactions that are sent first are prioritized.
Sort by Gas fee: Transactions that need urgent processing can pay a higher fee for priority.
Mainstream Layer 2 generally adopts the first method. However, there is no strict regulation on the sorting method for Layer 2; sorters can even sort arbitrarily, just like a bus driver can refuse to pick up passengers or reserve seats in advance for friends and family.
Can the sorter do evil? How to prevent it?
In theory, the sorter can act maliciously. It can reverse certain transactions and falsely report success, or mix in malicious transactions to profit.
To prevent malicious acts, different Layer 2 solutions have adopted different constraints.
Optimistic Rollup uses fraud proofs, during the dispute period ### usually one week ### if no one proves the data is incorrect, the submitted data will be permanently unchangeable.
ZK Rollup uses validity proofs to instantaneously validate each batch, obtaining final confirmation on Layer 1 without a dispute period.
![The principle, current status, and future of the Sequencer]###https://img-cdn.gateio.im/webp-social/moments-1813c3de7d443c219c8c39e54d7e4cc2.webp(
Current Situation: Problems Caused by Centralized Sorters
Currently, mainstream Layer 2 solutions such as OP Mainnet, Arbitrum One, Starknet, and zkSync Era all use centralized sequencers operated by official or affiliated organizations.
Centralized sorters offer many benefits for Layer 2 projects, such as ease of management, increased efficiency, and revenue generation. However, despite their promise to uphold user interests and avoid wrongdoing, they still raise concerns among users.
) weak censorship resistance
The censorship resistance of a single centralized entity operating a sequencer is far inferior to that of the many validators or miners of Layer 1. The team may be required to exclude certain transactions due to regulatory demands or blacklist some transactions. Although most Layer 2 designs have mechanisms that allow users to bypass the sequencer and submit transactions directly to Layer 1, users must incur additional costs.
( Weak Activity
Compared to thousands of transaction requests per second, a single centralized sorter may be unable to handle them simultaneously due to hardware and other reasons, leading to system downtime. For example, Arbitrum experienced a brief downtime during the distribution of airdrops.
) Obtain improper MEV profits
MEV### Maximum Extractable Value ### refers to the additional profit obtained by manipulating the order of transactions. Layer2 sorters are similar to Layer1 miners/validators and have the authority to manipulate the order of transactions. Although the sorters are operated by the Layer2 team, we still cannot fully trust them, especially since OP Mainnet uses a private memory pool, equivalent to a black box operation.
![The principle, current status, and future of the Sequencer]###https://img-cdn.gateio.im/webp-social/moments-0f00ea3d5262db98af1b562e7eaa327b.webp(
Future Development
Mainstream Layer 2 solutions have realized the issues with centralized sequencers and have proposed decentralized sequencer solutions. However, this is currently only reflected in official documents or white papers, and compared to the distribution of power and profits, they seem to be more focused on building core competitiveness.
) Decentralized Sorter
Several decentralized ranking solutions:
Geographical Decentralization: Deploy multiple sorters in different locations around the world, operated by reputable stakeholders, with sorting rights determined through rotation.
Sorter Auction: Auctions conducted through smart contracts, anyone can bid for the right to operate the sorter. The winner must stake a deposit to prevent malicious behavior.
Leader Election: Allows anyone to stake tokens, with the proposer being randomly selected each time a batch is submitted. The probability can be proportional to the amount staked.
Based Rollup: Layer 2 transaction ordering led by Ethereum validators, completely replacing the Layer 2's own sorter. This solution has high operational difficulty and still has technical issues to be resolved.
Shared Sorter
The shared sorter refers to the cancellation of individual Layer 2 dedicated sorters, allowing multiple Layer 2s to share a third-party sorting network.
Advantages include: atomic composability between Layer 2s, prevention of MEV extraction, etc. Currently, multiple projects are establishing shared sequencer networks, such as Astria, Radius, and Espresso.
Summary and Reflections
Can decentralized sorters or shared sorters perfectly solve the problems of centralized sorters? Not necessarily.
From the MEV perspective, after Ethereum's The Merge, block proposers have achieved significant REV extraction. Moderate arbitrage is beneficial for market stability, but excessive MEV extraction can harm user interests. If Rollup sorters are completely open, a similar market pattern may form.
While shared sorters can improve interoperability, if widely used, they may evolve into a powerful network controlling multiple Rollups, leading to new centralization issues.
Decentralization of blockchain is a long and difficult process. The attention on sorters is due to their important role in Rollup. I believe that through continuous exploration, the current problems will eventually be appropriately resolved.