pub struct ReplicationConfig {
pub enabled: bool,
pub node_id: String,
pub peer_nodes: Vec<String>,
pub conflict_resolution: ConflictResolution,
pub verify_checksums: bool,
}Expand description
Configuration for replication
Fields§
§enabled: boolWhether replication is enabled
node_id: StringUnique identifier for this node
peer_nodes: Vec<String>List of peer node IDs
conflict_resolution: ConflictResolutionConflict resolution strategy
verify_checksums: boolWhether to verify checksums
Implementations§
Source§impl ReplicationConfig
impl ReplicationConfig
Sourcepub fn with_peers(self, peers: Vec<String>) -> Self
pub fn with_peers(self, peers: Vec<String>) -> Self
Set peer nodes
Sourcepub fn conflict_resolution(self, strategy: ConflictResolution) -> Self
pub fn conflict_resolution(self, strategy: ConflictResolution) -> Self
Set conflict resolution strategy
Trait Implementations§
Source§impl Clone for ReplicationConfig
impl Clone for ReplicationConfig
Source§fn clone(&self) -> ReplicationConfig
fn clone(&self) -> ReplicationConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ReplicationConfig
impl Debug for ReplicationConfig
Auto Trait Implementations§
impl Freeze for ReplicationConfig
impl RefUnwindSafe for ReplicationConfig
impl Send for ReplicationConfig
impl Sync for ReplicationConfig
impl Unpin for ReplicationConfig
impl UnwindSafe for ReplicationConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more