transaction verification – When the UTXO within the cache is full, what technique is used to interchange one UTXO with one other within the cache?

0
78


The UTXO set cache just isn’t a set measurement and the restrict is not a tough restrict. New entries might be added to the cache with out regards for the utmost cache measurement. The truth is, the cache object itself would not even know what the restrict is.

Relatively what occurs is that the cache is flushed periodically. As a result of the UTXO set solely adjustments throughout block validation (mempool UTXO set is dealt with individually elsewhere), this periodic flushing is primarily tied to incoming blocks fairly than a timer. After every block is validated, the node determines whether or not it ought to flush the cache to disk. There are a number of circumstances that will trigger a flush, together with being near the cache restrict, and being over the cache restrict.

So if through the validation for a block, the cache turned full, it could really simply continue to grow till the block is absolutely validated. Then on the finish, your entire cache could be flushed to disk and the cache emptied.

Be aware that LevelDB itself has a cache that’s unbiased of the UTXO set cache.



Supply hyperlink

Leave a reply