helium / blockchain-core

Apache License 2.0
214 stars 85 forks source link

Use a CREAM cache for valid witnesses, not pdict #1449

Closed Vagabond closed 1 year ago

Vagabond commented 1 year ago

CREAM will evict naturally based on idle time and size, so use it to replace the pdict cache that was never collected and would leak memory.

PaulVMo commented 1 year ago

Go a little bigger on the max size? Aspirationally if we have have 1000 PoC per block (3x current rate) and conservatively if epochs are a little long at 50 blocks, we could easily need 50,000 items in the cache.