Skip to content

sui_v1.20.0_1709146490_ci

@mwtian mwtian tagged this 28 Feb 17:28
## Description 

`DagState::flush()` persists blocks, commits and last committed rounds
known to `DagState`. It is efficient in only writing out the delta from
the last `flush()` to storage. It must be called before proposing a
block to peers, and sending committed blocks to execution.

Additionally,
- When getting blocks by refs, check storage if they are not found in
memory.
- Crash on storage errors in DagState, because callers to DagState can
only panic on these errors as well.
- Clean up old blocks after each flush.
- Try to propose and commit immediately after Core recovery.

## Test Plan 

Unit tests.

---
If your changes are not user-facing and do not break anything, you can
skip the following section. Otherwise, please briefly describe what has
changed under the Release Notes section.

### Type of Change (Check all that apply)

- [ ] protocol change
- [ ] user-visible impact
- [ ] breaking change for a client SDKs
- [ ] breaking change for FNs (FN binary must upgrade)
- [ ] breaking change for validators or node operators (must upgrade
binaries)
- [ ] breaking change for on-chain data layout
- [ ] necessitate either a data wipe or data migration

### Release notes
Assets 2
Loading