Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Blockstore use clean-up #1122

Merged
merged 13 commits into from
Mar 10, 2020
Merged

Blockstore use clean-up #1122

merged 13 commits into from
Mar 10, 2020

Commits on Mar 6, 2020

  1. Add isBlockStored method to the repository

    This is a step towards limiting access to the block store. The long term
    goal is to allow only the repository to retrieve block data from the
    block store and pass it further.
    AlexandraRoatis committed Mar 6, 2020
    Configuration menu
    Copy the full SHA
    a4609e4 View commit details
    Browse the repository at this point in the history
  2. Move block store correction code in the repository

    As a result DBUtils no longer accesses the block store directly.
    AlexandraRoatis committed Mar 6, 2020
    Configuration menu
    Copy the full SHA
    9b2e84b View commit details
    Browse the repository at this point in the history
  3. Update messages in DBUtils to use a Logger

    The messages now give a better indications of when an error occured.
    AlexandraRoatis committed Mar 6, 2020
    Configuration menu
    Copy the full SHA
    5e01106 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    e070962 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    f52e93b View commit details
    Browse the repository at this point in the history
  6. Call getTotalDifficultyForHash from repository

    Reduces access to the block store by forwarding calls to the blockchain
    and repository. Also removed the unnecessary hash wrapping.
    AlexandraRoatis committed Mar 6, 2020
    Configuration menu
    Copy the full SHA
    f18fbab View commit details
    Browse the repository at this point in the history
  7. Move loadBlockchain out of AionHub

    Having all the functionality to load the blockchain inside the hub requires
    exposing data elements that would otherwise be kept private. Additionally,
    the method becomes easier to read when directly making use of the blockchain
    internal attributes.
    AlexandraRoatis committed Mar 6, 2020
    Configuration menu
    Copy the full SHA
    4526b2f View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    ba84ce9 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    679c185 View commit details
    Browse the repository at this point in the history
  10. Remove StandaloneBlockchain.setBlockNumber method

    The method is no longer used outside the test that checks its functionality.
    It was a hacky way of creating large chains for testing that can be replaced
    with the chain generation functionality from BlockchainTestUtils.
    AlexandraRoatis committed Mar 6, 2020
    Configuration menu
    Copy the full SHA
    c0bf3dd View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    0282a4d View commit details
    Browse the repository at this point in the history
  12. Configuration menu
    Copy the full SHA
    44a7108 View commit details
    Browse the repository at this point in the history
  13. Remove getBlockStore from the blockchain

    Access to the block store must go though the repository.
    AlexandraRoatis committed Mar 6, 2020
    Configuration menu
    Copy the full SHA
    50ea22d View commit details
    Browse the repository at this point in the history