1
0
mirror of synced 2025-01-25 15:09:07 +00:00
Daniel Sanchez 6287e554ae
consensus-engine to carnot-engine. (#551)
* Refactor: consensus-engine to carnot-engine.
Move under consensus/carnot-engine

* Fuzztests update with carnot-engine

* Update missing refactor in tests

---------

Co-authored-by: Gusto <bacvinka@gmail.com>
2024-01-04 15:09:43 +01:00

19 lines
518 B
Rust

use std::collections::HashSet;
use carnot_engine::{Block, NewView, TimeoutQc};
// State transtitions that will be picked randomly
#[derive(Clone, Debug)]
pub enum Transition {
Nop,
ReceiveSafeBlock(Block),
ReceiveUnsafeBlock(Block),
ApproveBlock(Block),
ApprovePastBlock(Block),
LocalTimeout,
ReceiveTimeoutQcForRecentView(TimeoutQc),
ReceiveTimeoutQcForOldView(TimeoutQc),
ApproveNewViewWithLatestTimeoutQc(TimeoutQc, HashSet<NewView>),
//TODO: add more corner transitions
}