1

My question is possibly naive but since I am facing a similar problem, I would like to know how does ethereum really know which addresses are validator addresses without storing a 300k long array?

If it's done with some mapping I would also be curious to hear the details.

3 Answers 3

1

If you want to use a block explorer, you can see validators as those with valid deposits to the deposit contract.

There's over a billion transactions on the chain so the number of validators is tiny in comparison. Each client will have their own format for storing these on your hard drive.

At the client specification level, it is simply a list:

validators: List[Validator, VALIDATOR_REGISTRY_LIMIT]

Validators are appended as their deposit is processed:

state.validators.append(get_validator_from_deposit(deposit))

0

possibly they use merkle trees to store the details as storing tremendous amounts of data is very costly in blockchain

0

The Ethereum 2.0 deposit contract uses merkle tree.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.