//! Distributed Mode for Dakera
//!
//! Provides distributed vector search capabilities:
//!
//! - **Sharding**: Consistent hashing and range-based partitioning
//! - **Routing**: Scatter-gather query execution across shards
//! - **Replication**: Read replicas with automatic failover
//! - **Coordination**: Cluster membership and health monitoring
//! - **Load Balancing**: Request distribution strategies
//! - **Gossip Protocol**: Automatic node discovery and failure detection
//! - **Replica Management**: Configurable placement and synchronization
//! - **Leader Election**: Lease-based election for write coordination
//! - **Rolling Upgrades**: Coordinated cluster upgrades with rollback support
//! - **Auto Rebalancing**: Automatic shard redistribution on topology changes

pub mod cluster;
pub mod election;
pub mod gossip;
pub mod rebalance;
pub mod replication;
pub mod routing;
pub mod sharding;
pub mod upgrades;

pub use cluster::{
    ClusterConfig, ClusterCoordinator, ClusterState, NodeHealth, NodeInfo, NodeRole, NodeStatus,
};
pub use election::{
    ElectionConfig, ElectionError, ElectionEvent, ElectionManager, ElectionState, ElectionStats,
    LeaderElection, LeaderInfo, Vote, VoteRequest,
};
pub use gossip::{
    GossipConfig, GossipError, GossipEvent, GossipMember, GossipMessage, GossipProtocol,
    MemberState, MemberStateUpdate,
};
pub use rebalance::{
    MoveState, NodeLoad, RebalanceConfig, RebalanceError, RebalanceManager, RebalancePlan,
    RebalanceState, RebalanceStats, RebalanceTrigger, ShardMove,
};
pub use replication::{
    NodeTopology, PlacementStrategy, ReplicaInfo, ReplicaManager, ReplicaSet, ReplicaState,
    ReplicationConfig, ReplicationError, ReplicationStats, WriteAckMode,
};
pub use routing::{QueryRouter, RouterConfig, RoutingStrategy};
pub use sharding::{
    ConsistentHashRing, PartitionInfo, ShardAssignment, ShardingConfig, ShardingStrategy,
};
pub use upgrades::{
    NodeUpgradeInfo, NodeUpgradeState, UpgradeConfig, UpgradeError, UpgradeManager, UpgradePlan,
    UpgradeStats, UpgradeStatus, Version,
};
