ethereum / trin

An Ethereum portal client: a json-rpc server with nearly instant sync, and low CPU & storage usage
365 stars 113 forks source link

feat: use RocksDB for state execution #1318

Closed KolbyML closed 3 months ago

KolbyML commented 3 months ago

What was wrong?

We are storing the whole Ethereum state in memory

How was it fixed?

Store it in RocksDB.

We use sqlite for the rest of Trin, but this design choice doesn't make sense for executing the state. We need to use a KV store regardless it doesn't take more work to do it now, so I am doing it now.

Performance does matter and sqldb can't compete, executing the state is very strict when it comes to performance, so it just didn't make sense to use sql