himesh.eth 🦇 🔊 Profile picture
Aug 8, 2022 43 tweets 8 min read Read on X
After The Merge │ Part 1: The Surge 🌊

Act 1: Why do we need the Surge?

#Ethereum #TheMerge #TheSurge

(1/41) Image
The ‘Merge’ refers to Ethereum’s upcoming transition from Proof-of-Work to Proof-of-Stake, and is currently scheduled for mid-September 2022.

This begs the question: What’s left for Ethereum to do after it moves to Proof-of-Stake, a stated goal since 2014?

(2/41)
The answer: plenty!

On 2 December 2021, @VitalikButerin shared a diagram showing Ethereum’s post-Merge protocol development roadmaps - namely the Surge, Verge, Purge & Splurge.

(3/41)
These post-Merge roadmaps are not sequential to each other but are being worked on concurrently.

The purpose of this thread is to discuss the Surge in more detail, including how things have changed for this roadmap since the diagram was first shared.

(4/41)
In order to fully appreciate why the Surge is necessary, we will need to discuss:

1️⃣ the blockchain trilemma,

2️⃣ the different layers that comprise a blockchain, and

3️⃣ rollups.

(5/41)
1️⃣ The blockchain trilemma was first proposed by @VitalikButerin back in 2017, and later visualised in in 2021.

It states that, when sticking to ‘simple’ techniques, a blockchain’s developers can only optimise for two of the given three properties at any given time.

(6/41) Image
These three properties are:

📈 Scalability, i.e. the blockchain can handle a high throughput of transactions, usually measured as transactions-per-second (TPS).

(7/41)
🌐 Decentralisation, i.e. there are many ‘consensus’ full nodes securing the network by storing the blockchain data and/or verifying validated blocks and subsequent state changes.

(8/41)
🔒 Security, i.e. the blockchain can resist a large percentage of ‘validation’ full nodes (i.e. those that propose and/or validate blocks) trying to attack it.

So where does Ethereum fit into all of this?

(9/41)
Ethereum can be considered a 'traditional blockchain'.

These blockchains rely on many consensus nodes verifying transactions, and as such the chains are decentralised and secure ...

(10/41)
... but this reliance on each node having to verify each transaction means that the TPS (and hence scalability) of these blockchains is constrained by the (intentionally) limited hardware requirements to run a node.

(11/41)
As such, there is a balance to be struck between increasing node hardware requirements (which would mean being able to verify more transactions, increasing TPS and opening up the possibility of bigger blocks) ...

(12/41)
... versus these increased requirements pricing out more people from running nodes, and hence worsening decentralisation and security.

(13/41)
The key question is then:

How does the Ethereum protocol increase scalability without compromising the existing strong decentralisation and security of the chain, and thus ‘solve’ the trilemma?

(14/41)
2️⃣ The different layers that comprise a blockchain.

Whilst we may think of a blockchain as a series of blocks being linked together over time, the stages which encapsulate this process can be contextualised as three different ‘layers’:

(15/41)
🪓 Execution layer: This layer refers to the transaction requests that should get executed when they are included in any given proposed block by a block proposer (i.e. a miner or validator).

(16/41)
💽 Data availability layer: This layer refers to the transaction data from proposed blocks that the block proposer needs to broadcast and make available to the network so that full nodes can verify the block proposer’s work.

(17/41)
🗣️ Consensus layer: This layer refers to the consensus mechanism used by the blockchain, specifically:

👬🏻 the Sybil resistance mechanism, in terms of either mining (in PoW) or proposing (in PoS) as a method of collating valid transaction requests into a block

and ...

(18/41)
...

⛓️ the chain selection rule used, in terms of the act of verification of the mined/proposed block performed by full nodes and its eventual appending onto the tail of the blockchain.

(19/41)
Now we have this high-level understanding of the three layers, we can see that Ethereum’s upcoming transition from PoW to PoS is actually a significant change to the *consensus layer* of the blockchain only - the execution and data availability layers remain unchanged.

(20/41)
This transition being called the ‘Merge’ actually refers to the ‘merging’ of the execution and data availability layers of Ethereum with the new consensus layer provided by what’s called the ‘Beacon Chain’.

(21/41)
The Surge itself then is focused on resolving bottlenecks in the data availability layer which will emerge as a result of rollups becoming Ethereum’s main execution engine.

So, what are rollups?

(22/41)
3️⃣ Rollups

In 2020, Ethereum announced its intention to lean in fully to a rollup-centric roadmap.

What does this mean exactly?

ethereum-magicians.org/t/a-rollup-cen…

(23/41)
Well, everything I wrote above around execution, data availability and consensus layers refers to the Ethereum blockchain, which is alternatively called the Ethereum main network (or mainnet).

(24/41)
Let’s now call this Ethereum mainnet a ‘Layer 1’ blockchain (this use of capital-L ‘Layer’ should not be confused with the other three lowercase ‘layers’).

(25/41)
Let’s now imagine a Layer 2 blockchain, existing separate to the Layer 1, executing transactions for users interacting directly with it, and maintaining its own state.

In Layer 2 terminology, the specific node processing these transactions is called a sequencer.

(26/41)
Furthermore, let’s imagine this Layer 2 sequencer then ‘rolls up’ hundreds of these transactions into a single bundle and submits this bundle wholesale (with the accompanying underlying transaction data) as a single transaction onto the Layer 1’s execution layer.

(27/41)
By regularly posting these bundled transactions onto the Layer 1’s execution layer, the Layer 2 (or 'rollup' in this instance) allows the transactions within these bundles to use the consensus layer of the Layer 1, inheriting its superior security and decentralisation.

(28/41)
The Layer 1’s execution layer itself also benefits as the Layer 2 removes these transactional loads from the Layer 1’s execution layer - them being a key source of congestion - which in turn improves scalability at the Layer 1’s execution layer.

(29/41)
There are two types of rollups worth noting:

😇 Optimistic rollups are ones where the transactions are trusted to be valid by the Layer 1 by default. The Layer 2 sequencer attests to this validity and posts collateral called a deposit to back it.

(30/41)
However, the Layer 2 has its own independent verifier nodes that will process the transactions themselves and will be able to raise a challenge if they get a different result, providing their own deposit as collateral to back the challenge.

(31/41)
When there is a challenge, a fraud proof computation will get posted to the Layer 1 as another transaction and all Layer 1 full nodes will run and verify the fraud proof computation as part of their normal transaction execution process.

(32/41)
Whichever of the two parties is wrong loses their deposit, and all transactions that depend on the result of that computation are recomputed.

(33/41)
👁️‍🗨️ Zero knowledge (or ZK) rollups involve a form of cryptographic proof (or validity proof), published by the sequencer, that directly proves that the transactions posted from the Layer 2 are valid. It’s impossible to produce a validity proof for an invalid block.

(34/41)
In both cases, large amounts of transaction data are posted onto the Layer 1. The speed at which this Layer 2 can post this data is limited by the throughput of the Layer 1's underlying DA layer.

As such, scalability solutions need to be found at the DA layer.

(35/41)
Bringing it all together:

🌟 Ethereum is a ‘traditional’ blockchain currently emphasising decentralisation and security over scalability.

🌟 Scalability solutions can be sought at both the execution and data availability layers of the blockchain.

(36/41)
🌟 Execution layer scaling is aimed to be achieved through rollups, which remove heavy transactional loads away from the Layer 1 to an off-chain Layer 2.

(37/41)
🌟 However, this solution will still face throughput bottlenecks at the Layer 1 data availability layer when these Layer 2 rollups start posting large amounts of transactional data onto the Layer 1.

(38/41)
🌟 And so the next major development of Ethereum is aiming to remove these bottlenecks by implementing scalability solutions at the data availability layer.

(39/41)
Which is *precisely* what the Surge is planning to do, through something called data sharding! 🙌

Next time:

Act 2: The original data sharding design.

(40/41)
I go into more detail on everything related to the Surge in my Substack post.

himesh.substack.com/p/after-the-me…

(41/41)
If you've got this far, thank you! 🙏

Liked what you read? Please help me spread the word by retweeting the thread (linked below).

And follow me for more explainers on Ethereum, including the rest of the Surge series. 💡

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with himesh.eth 🦇 🔊

himesh.eth 🦇 🔊 Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @himeshdoteth

Sep 21, 2022
After The Merge │ Part 2: The Verge 🏔️

#Ethereum #TheMerge #TheVerge

(1/28)
The Verge in a nutshell:

- Replaces the state Merkle tree with a Verkle tree...
- ...which allows for builders to attach Verkle proofs to their blocks...
- ...allowing validators to statelessly verify blocks.

What does this word salad mean?

First, some context:

(2/28)
A lot of information goes into the block header of a block...

...including something called the *stateRoot*, defined as:
- the hash...
- of the root node...
- of the state Merkle tree...
- after all the transactions included in the block have been executed.

(3/28)
Read 29 tweets
Jun 7, 2022
Ethereum's Proof-of-Work vs Proof-of-Stake - A Definitive Guide

As #Ethereum moves closer to #TheMerge 🐼, there’s going to be a *ton* of misinformation and FUD coming out in the coming weeks.

This unbiased 🧵 assesses how well PoW and PoS fare in key areas of interest.

(1/49)
🛡️Security - PoW

51% of network computing power is needed to defraud the chain, requiring prohibitively expensive investments in equipment and energy.

There are also penalties for miners submitting incorrect blocks via sunk costs in computing power, time and energy.

(2/49)
🛡️Security - PoW cont.

Under a 51% attack, there is no real mechanism to prevent attackers from continuously and endlessly attacking the chain (as malicious mining GPUs can't be isolated), rendering the chain useless (known as a Spawn-Camp Attack).

(3/49)
Read 50 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Don't want to be a Premium member but still want to support us?

Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal

Or Donate anonymously using crypto!

Ethereum

0xfe58350B80634f60Fa6Dc149a72b4DFbc17D341E copy

Bitcoin

3ATGMxNzCUFzxpMCHL5sWSt4DVtS8UqXpi copy

Thank you for your support!

Follow Us!

:(