omnipaxos/
lib.rs

1//! OmniPaxos is a library for implementing distributed replicated logs with strong consistency guarantees
2//! that provides seamless reconfiguration while also being completely resilient to partial network partitions.
3//! This library provides the distributed log abstraction as a black-box for the user, where the user only has to
4//! provide its desired network and storage implementations.
5//!
6//! # Crate feature flags
7//! The following crate feature flags are available. They are configured in your Cargo.toml.
8//! * `batch_accept` - Batch multiple log entries into a single message to reduce overhead.
9//! * `logging` - System-wide logging with the slog crate
10//! * `toml_config` - Create an OmniPaxos instance from a TOML configuration file
11//! * `serde` - Serialization and deserialization of messages and internal structs with serde. Disable this if you want to implement your own custom ser/deserialization or want to store data that is not serde-supported.
12
13#![cfg_attr(docsrs, feature(doc_auto_cfg))]
14#![deny(missing_docs)]
15/// Trait and struct related to the leader election in Omni-Paxos.
16pub mod ballot_leader_election;
17/// OmniPaxos error definitions
18pub mod errors;
19/// The different messages OmniPaxos servers can communicate to each other with.
20pub mod messages;
21/// The user-facing OmniPaxos struct.
22mod omni_paxos;
23pub use omni_paxos::*;
24
25/// The core replication algorithm of OmniPaxos.
26pub(crate) mod sequence_paxos;
27/// Traits and structs related to the backend storage of an OmniPaxos server.
28pub mod storage;
29
30#[cfg(feature = "unicache")]
31/// Traits, structs, and types related to the unicache.
32pub mod unicache;
33/// A module containing helper functions and structs.
34pub mod util;
35/// A module containing helper functions and structs.
36pub mod utils;
37
38#[cfg(feature = "macros")]
39#[allow(unused_imports)]
40#[macro_use]
41extern crate omnipaxos_macros;
42
43#[cfg(feature = "macros")]
44/// Macros in the omnipaxos crate
45pub mod macros {
46    #[doc(hidden)]
47    pub use omnipaxos_macros::*;
48}