Crate rhododendron[][src]

BFT Agreement based on a rotating proposer in different rounds, generic futures-based implementation.

Attempt to reach BFT agreement on a candidate. Not ready for production.

Agreement is between n nodes, max_faulty of whom are faulty. max_faulty should be less than 1/3 of nodes, otherwise agreement may never be reached.

Initiate agreement by calling agree with a generic Context, an input stream, and an output sink. The input should never logically conclude and contain messages from all other nodes, while the output sink

Note that it is possible to witness agreement being reached without ever seeing the candidate. Any candidates seen will be checked for validity.

Although technically the agreement will always complete (given the eventual delivery of messages), in practice it is possible for this future to conclude without having witnessed the conclusion.

Users of the Agreement future should schedule it to be pre-empted by an external import of an agreed value.

Re-exports

pub use self::accumulator::Accumulator;
pub use self::accumulator::Justification;
pub use self::accumulator::PrepareJustification;
pub use self::accumulator::UncheckedJustification;
pub use self::accumulator::Misbehavior;

Modules

accumulator

Vote accumulator for each round of BFT consensus.

Structs

Agreement

Future that resolves upon BFT agreement for a candidate.

Committed

Committed successfully.

InputStreamConcluded

Error returned when the input stream concludes.

LocalizedProposal

A localized proposal message. Contains two signed pieces of data.

LocalizedVote

A localized vote message, including the sender.

Enums

AdvanceRoundReason

A reason why we are advancing round.

Communication

Communication that can occur between participants in consensus.

LocalizedMessage

A localized message.

Message

Messages over the proposal. Each message carries an associated round number.

Vote

Votes during a round.

Traits

Context

Context necessary for agreement.

TypeResolve

Hack to get around type alias warning.

Functions

agree

Attempt to reach BFT agreement on a candidate.