Skip to content

tech debt: ledger state snapshots should contain complete state #4607

Open
@marta-lokhova

Description

@marta-lokhova

We're moving towards individual subsystems in core relying on read-only snapshots to query ledger state. There are several data structures that together comprise a complete "ledger state": the bucketlist, ledger header, and soroban config. The problem is that currently all these pieces of ledger state live in different places. Specifically, ledger header and soroban config live inside the LedgerManager, while the bucketlist lives inside of the bucketlist snapshot. This is quite error-prone and it definitely a footgun. It would be much easier to reason about consistency of ledger state snapshots if all relevant pieces lived inside of a single snapshot object. There is some WIP changes in #4597 already, which we can probably revive when we prioritize this.

Metadata

Metadata

Assignees

Labels

bugcleanuprefactoring or other internal improvements

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions