hashgraph / hedera-services

Crypto, token, consensus, file, and smart contract services for the Hedera public ledger
Apache License 2.0
265 stars 119 forks source link

Drive decision on single VirtualMap or binary tree #14099

Open poulok opened 3 days ago

poulok commented 3 days ago

This ticket is complete when there is a decision by the system architects. The work for the assignee is to drive the conversation, setup meetings, participate in performance test, etc - anything required to get a decision made.

A decision matrix would be helpful. There are some pros and cons apart from performance. This ticket includes documenting these pros and cons. Some are listed below.

Cons to a single Virtual Map:

  1. Lose the ability to have small state proofs that are local to a small virtual map
  2. It's cheaper to rehash a smaller, specific virtual map when changes are made

Pros to a single Virtual Map:

  1. Average depth goes down