nimbus-eth1/nimbus/sync/snap/worker/com
Jordan Hrycaj 4ff0948fed
Snap sync accounts healing (#1225)
* Added inspect module

why:
  Find dangling references for trie healing support.

details:
 + This patch set provides only the inspect module and some unit tests.
 + There are also extensive unit tests which need bulk data from the
   `nimbus-eth1-blob` module.

* Alternative pivot finder

why:
  Attempt to be faster on start up. Also tying to decouple pivot finder
  somehow by providing different mechanisms (this one runs in `single`
  mode.)

* Use inspect module for healing

details:
 + After some progress with account and storage data, the inspect facility
   is used to find dangling links in the database to be filled nose-wise.
 + This is a crude attempt to cobble together functional elements. The
   set up needs to be honed.

* fix scheduler to avoid starting dead peers

why:
  Some peers drop out while in `sleepAsync()`. So extra `if` clauses
  make sure that this event is detected early.

* Bug fixes causing crashes

details:

+ prettify.toPC():
  int/intToStr() numeric range over/underflow

+ hexary_inspect.hexaryInspectPath():
  take care of half initialised step with branch but missing index into
  branch array

* improve handling of dropped peers in alternaive pivot finder

why:
  Strange things may happen while querying data from the network.
  Additional checks make sure that the state of other peers is updated
  immediately.

* Update trace messages

* reorganise snap fetch & store schedule
2022-09-16 08:24:12 +01:00
..
get_account_range.nim Snap sync accounts healing (#1225) 2022-09-16 08:24:12 +01:00
get_byte_codes.nim Snap sync accounts healing (#1225) 2022-09-16 08:24:12 +01:00
get_error.nim Snap sync accounts healing (#1225) 2022-09-16 08:24:12 +01:00
get_storage_ranges.nim Snap sync accounts healing (#1225) 2022-09-16 08:24:12 +01:00
get_trie_nodes.nim Snap sync accounts healing (#1225) 2022-09-16 08:24:12 +01:00