aleph_bft/
lib.rs

1//! Implements the Aleph BFT Consensus protocol as a "finality gadget". The [run_session] function
2//! requires access to a network layer, a cryptographic primitive, and a data provider that
3//! gives appropriate access to the set of available data that we need to make consensus on.
4
5mod alerts;
6mod collection;
7mod config;
8mod consensus;
9mod creation;
10mod dag;
11mod dissemination;
12mod extension;
13mod interface;
14mod network;
15mod terminator;
16mod units;
17
18mod backup;
19mod task_queue;
20#[cfg(test)]
21mod testing;
22
23pub use aleph_bft_types::{
24    Data, DataProvider, FinalizationHandler, Hasher, IncompleteMultisignatureError, Index, Indexed,
25    Keychain, MultiKeychain, Multisigned, Network, NodeCount, NodeIndex, NodeMap, NodeSubset,
26    OrderedUnit, PartialMultisignature, PartiallyMultisigned, Recipient, Round, SessionId,
27    Signable, Signature, SignatureError, SignatureSet, Signed, SpawnHandle, TaskHandle,
28    UncheckedSigned, UnitFinalizationHandler,
29};
30pub use config::{
31    create_config, default_config, default_delay_config, exponential_slowdown, Config, DelayConfig,
32};
33pub use consensus::run_session;
34pub use interface::LocalIO;
35pub use network::NetworkData;
36pub use terminator::{handle_task_termination, Terminator};
37
38type Receiver<T> = futures::channel::mpsc::UnboundedReceiver<T>;
39type Sender<T> = futures::channel::mpsc::UnboundedSender<T>;