pub const MAX_NON_FINALIZED_CHAIN_FORKS: usize = 10;
Expand description
The maximum number of non-finalized chain forks Zebra will track. When this limit is reached, we drop the chain with the lowest work.
When the network is under heavy transaction load, there are around 5 active forks in the last 100 blocks. (1 fork per 20 blocks.) When block propagation is efficient, there is around 1 fork per 300 blocks.
This limits non-finalized chain memory to around:
10 forks * 100 blocks * 2 MB per block = 2 GB