This can be expensive and add up to considerable CPU, see #611
For blocks retrieved from the block log this is unnecessary. Also note with Savanna, blocks are moved out of the fork database into the block log much quicker. The serialization format on disk is the same as on P2P.
Add a new controller interfaces: fetch_serialied_block_by_number and fetch_serialized_block_by_id. These would pull directly from the block log without having to deserialize/serialize or from the forkdb where serialization would be required. Use these new interfaces in net_plugin to provide blocks to peers.
Currently, when a peer asks for a block:
This can be expensive and add up to considerable CPU, see #611
For blocks retrieved from the block log this is unnecessary. Also note with Savanna, blocks are moved out of the fork database into the block log much quicker. The serialization format on disk is the same as on P2P.
Add a new controller interfaces:
fetch_serialied_block_by_number
andfetch_serialized_block_by_id
. These would pull directly from the block log without having to deserialize/serialize or from the forkdb where serialization would be required. Use these new interfaces innet_plugin
to provide blocks to peers.