Skip to content

[Protocol KVStore] Move EpochProtocolState data into KVStore #5974

Open

Description

At the moment we only store the hash of Epoch sub-state in the KVStore. We'd like to directly store all the data there instead.

Suggested implementation

  • keep original Snapshot.Epoch API, but back it by the KV-store (this prevents needing to update/refactor all existing usages)
  • no (remove) top-level "getter" Snapshot.EpochProtocolState
  • top-level access to Epoch-data is still given through KV-Store's canonical representation (interface according to the newest protocol version 👉 KVStoreReader)

Clean up duplicated epoch API at the same time?

Historically grown, the Epoch portion of the Protocol state is exposed in three different places in our APIs (see #5650 (comment)). We would like to consolidate this.

See also #6191

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    PreserveStale Bot repellentProtocolTeam: Issues assigned to the Protocol Pillar.S-BFT

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions