Modeling Stateless Ethereum: A Journey Into The Unknown
What is Stateless Ethereum?
Before we ask “What is Stateless Ethereum”, we first need to answer the question “What is state?” and why do we want to “get rid of it”?
The Ethereum world state contains all Ethereum accounts, their balances, deployed smart contracts, and associated storage. New accounts are continually being added and new smart contracts are being deployed. Therefore, by design, the state size of Ethereum keeps growing ad infinitum.
The implication of this unbounded state growth is that it takes longer and uses more space to spin up a new full node. Consequently, the cost increases and it becomes less attractive for new full nodes to join the Ethereum network.
Vitalik Buterin recognised these issues back in 2017 when he first introduced the concept of Stateless Ethereum. The primary aim of Stateless Ethereum is to make Ethereum scale, by mitigating unbounded state growth.
Stateless is a misnomer
In reality, “stateless” does not really mean “no state”! What it actually means is that you made state someone else’s problem…Ben Edgington, What’s New in Eth2
In other words, you passed the responsibility of provisioning and storing the Ethereum world state on to another participant in the network. Therefore, stateless is actually a misnomer and a stateless Ethereum client is not completely stateless, but chooses the state it wants to maintain.
A stateless Ethereum client should be able to choose the state that it wants to keep up to date. Conversely, it should be able to disregard state which is of no interest to it.
The key mechanism to enable Stateless Ethereum is a block “witness.” Therefore, in Stateless Ethereum, when clients receive validated blocks from miners, they will also receive its corresponding witness. This block witness consists of all the data required to execute the transactions contained in that block.
The upshot of this is that there will be more data packets being passed around the network. We therefore need to assess the impact that this may have on the network, to ensure that the Ethereum ecosystem continues to operate securely and efficiently in this altered environment.
This leads to the key question: Is Stateless Ethereum feasible? To answer this question we turn to the world of modelling.
Modeling is the approach we typically use when we want to predict the future, or explore unintentional knock-on effects that may occur when changes are made to a stable functioning environment.
Stateless Ethereum is such an environment. The current Ethereum network is known and functions well. We have access to a lot of empirical data. We also have a good understanding of how it works. If we now introduce statelessness into this equilibrium, a reasonable question is: how will the altered system adjust and operate? These are the unknowns we want to better understand. For example, what are the worst and best case scenarios when we implement Stateless Ethereum?
Modeling helps us capture what we know, and facilitates the exploration of that which we do not know. Building on our knowledge of the known, we can model key processes and interactions in the system we are studying. For the unknowns, we use probabilities to represent uncertainties in the model. We also consult with experts who have in-depth knowledge of the current system, or problem. Representing their knowledge in the model is crucial to identify those processes that may be affected by the changes.
When building a model, we aim to balance necessary system detail with model compactness. It is often tempting to include all factors that may potentially influence an outcome, or form part of a complex process. However, some may not contribute in a meaningful way to the overall behaviour of the system and merely increase model clutter. Therefore, we consult with experts to identify ‘key factors’ that best capture the behaviour of the system, or parts thereof. Moreover, the behaviour exhibited by less relevant detail is often already contained within the behaviour of the key factors.
Next week in this series, we will explain our approach to model Stateless Ethereum.
If you would like more information about the project, please get in touch with me via email.