pub struct AdaptiveDhtConfig {
pub block_threshold: f64,
}Expand description
Configuration for the AdaptiveDHT layer
Fields§
§block_threshold: f64Trust score below which a peer is evicted from the routing table and blocked from sending DHT messages or being re-added to the RT. Eviction is immediate when a peer’s score crosses this threshold. Default: 0.15
Implementations§
Trait Implementations§
Source§impl Clone for AdaptiveDhtConfig
impl Clone for AdaptiveDhtConfig
Source§fn clone(&self) -> AdaptiveDhtConfig
fn clone(&self) -> AdaptiveDhtConfig
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 AdaptiveDhtConfig
impl Debug for AdaptiveDhtConfig
Source§impl Default for AdaptiveDhtConfig
impl Default for AdaptiveDhtConfig
Source§impl<'de> Deserialize<'de> for AdaptiveDhtConfigwhere
AdaptiveDhtConfig: Default,
impl<'de> Deserialize<'de> for AdaptiveDhtConfigwhere
AdaptiveDhtConfig: Default,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for AdaptiveDhtConfig
impl RefUnwindSafe for AdaptiveDhtConfig
impl Send for AdaptiveDhtConfig
impl Sync for AdaptiveDhtConfig
impl Unpin for AdaptiveDhtConfig
impl UnsafeUnpin for AdaptiveDhtConfig
impl UnwindSafe for AdaptiveDhtConfig
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