Skip to content
This repository has been archived by the owner on Aug 2, 2022. It is now read-only.

DAWN-487 ⁃ Update Chainbase to Support Scoping #525

Closed
7 tasks
bytemaster opened this issue Sep 29, 2017 · 3 comments
Closed
7 tasks

DAWN-487 ⁃ Update Chainbase to Support Scoping #525

bytemaster opened this issue Sep 29, 2017 · 3 comments
Assignees

Comments

@bytemaster
Copy link
Contributor

bytemaster commented Sep 29, 2017

Currently chainbase makes some assumptions that are not valid for EOS.IO:

  • the set of tables is static
  • undo / redo applies to all tables which is not sustainable

Going forward we will require the following:

  • scoped tables
  • dynamic table creation
  • scoped undo history
    • dynamic addition of tables as they are modified

After reviewing the design of chainbase I have concluded the following usage pattern will be necessary going forward:

  • all create, modify, and remove commands must be triggered from the undo session
    • this is done to ensure that the impacted tables have the proper revision history, current
      implementation can skip this because ALL tables have undo started at same time, but going
      forward this will have to be sparse.
  • all child undo sessions must be created from the current undo session
  • in debugging mode we need to ensure that all access to create/modify/remove is through a single strand

When the last irreversible block comes along we discard old / unneeded undo states via the commit() call. We currently iterate over all tables (which are statically typed) and delete unnecessary undo state. This won't be possible going forward unless we include the undo sessions in the shared memory.

@bytemaster bytemaster self-assigned this Sep 29, 2017
@blockone-syncclient blockone-syncclient changed the title Update Chainbase to Support Scoping DAWN-487 ⁃ Update Chainbase to Support Scoping Jan 16, 2018
@andriantolie
Copy link
Contributor

@bytemaster is this still relevant?

@brianjohnson5972
Copy link
Contributor

@wanderingbort or @heifner This looks like this is OBE because it was written so many designs ago. If I hear nothing back from you I will close it.

@brianjohnson5972
Copy link
Contributor

Code has been refactored multiple times since this was written, so it is OBE

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants