v5 functional updates #339

Merged
telackey merged 64 commits from ian/v5_dev into v1.10.26-statediff-v5 2023-03-23 18:25:21 +00:00
Member

Will close https://github.com/cerc-io/go-ethereum/issues/196, https://github.com/cerc-io/go-ethereum/issues/165, https://github.com/cerc-io/go-ethereum/issues/236, https://github.com/cerc-io/go-ethereum/issues/266, https://github.com/cerc-io/go-ethereum/issues/277

The main changes in v5 are:

Database changes:

  • uncle_hash => uncles_hash
  • mh_key => cid
  • state_cids now only stores leaf nodes, so the PK can use leaf_key in its tuple
  • state_accounts table internalized into state_cids since each record corresponds to an account now
  • storage_cids now only stores leaf nodes, so the PK can use leaf_key in its tuple
  • leaf_cid => cid in receipt_cids and log_cids tables
  • no more access_list_elements table
  • public.blocks => ipld.blocks

Statediff process changes:

  • no longer write log trie, tx trie, and rct trie IPLD objects to ipld.blocks (we can materialize them on demand if needed, or cache using a "proof watcher")
  • fix internalized leaf node issues

Misc:

  • refactor ipld package
  • removed a shit ton of now (or, in some cases, also previously) unused code

TODO:

Going to do the remaining TODOs in a separate PRs. This one is large enough,

Will close https://github.com/cerc-io/go-ethereum/issues/196, https://github.com/cerc-io/go-ethereum/issues/165, https://github.com/cerc-io/go-ethereum/issues/236, https://github.com/cerc-io/go-ethereum/issues/266, https://github.com/cerc-io/go-ethereum/issues/277 The main changes in v5 are: Database changes: - `uncle_hash` => `uncles_hash` - `mh_key` => `cid` - `state_cids` now only stores leaf nodes, so the PK can use `leaf_key` in its tuple - `state_accounts` table internalized into `state_cids` since each record corresponds to an account now - `storage_cid`s now only stores leaf nodes, so the PK can use `leaf_key` in its tuple - `leaf_cid` => `cid` in `receipt_cids` and `log_cids` tables - no more `access_list_elements` table - `public.blocks` => `ipld.blocks` Statediff process changes: - no longer write log trie, tx trie, and rct trie IPLD objects to `ipld.blocks` (we can materialize them on demand if needed, or cache using a "proof watcher") - fix internalized leaf node issues Misc: - refactor ipld package - removed a shit ton of now (or, in some cases, also previously) unused code TODO: - [ ] Cherry-pick Thomas' work - [x] https://github.com/cerc-io/go-ethereum/issues/338 - [x] Figure out remaining bug I suspect is related to https://github.com/cerc-io/go-ethereum/pull/247/files/0438809cb493d990e52cdb1310c22745b679a517#r908033293 and how we are fixing the internal leaf node issue - [ ] Rebase to 1.11.5 Going to do the remaining TODOs in a separate PRs. This one is large enough,
roysc reviewed 2023-03-15 23:31:10 +00:00
dboreham reviewed 2023-03-15 23:31:10 +00:00
telackey reviewed 2023-03-15 23:31:10 +00:00
Author
Member

@roysc pinging you just so you are aware of this, no need to review atm.

@roysc pinging you just so you are aware of this, no need to review atm.
Author
Member

Merging this, cherry-pick PR otw.

Merging this, cherry-pick PR otw.
Sign in to join this conversation.
No reviewers
No Milestone
No project
No Assignees
4 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: cerc-io/go-ethereum#339
No description provided.