This commit adds a config file option in server settings called disable_checkpoints
Fast Sync with pow skipping now covers three different usage cases:
User sets ONLYskip_pow_validation = true
results in skipping of pow validation on all blocks up to last checkpoint (2,050,000 in source)
User sets skip_pow_validation = true AND disable_checkpoints = true
results in fast sync all the way to chaintip (pow validation begins only once we've synced all historical blocks)
User sets neither
results in full-chain validation.
This also required some code refactoring to accommodate the new mechanics, and config file access through inheritance. I actually like this implementation a lot better, as it is easier to follow than the previous.
Finally, it resolves an omission I made, in original submission of skip_pow_validation functionality (not sure it would have made a difference, but its resolved here also)
Small hack for quicker testing: comment out the newer checkpoints and recompile... same effect willl trigger at whichever height is included in the last checkpoint.
This commit adds a config file option in server settings called
disable_checkpoints
Fast Sync with pow skipping now covers three different usage cases:
User sets ONLY
skip_pow_validation = true
User sets
skip_pow_validation = true
ANDdisable_checkpoints = true
User sets neither
This also required some code refactoring to accommodate the new mechanics, and config file access through inheritance. I actually like this implementation a lot better, as it is easier to follow than the previous.
Finally, it resolves an omission I made, in original submission of
skip_pow_validation
functionality (not sure it would have made a difference, but its resolved here also)