pub struct TcpNetworkConfig {
pub bind_addr: SocketAddr,
pub peer_addresses: HashMap<NodeId, SocketAddr>,
pub connection_timeout: Duration,
pub keepalive_interval: Duration,
pub max_message_size: usize,
pub retry_config: RetryConfig,
pub buffer_config: BufferConfig,
}Expand description
Configuration for TCP networking
Fields§
§bind_addr: SocketAddrLocal address to bind to
peer_addresses: HashMap<NodeId, SocketAddr>Known peer addresses for initial connection
connection_timeout: DurationConnection timeout
keepalive_interval: DurationKeep-alive interval
max_message_size: usizeMaximum message size (in bytes)
retry_config: RetryConfigConnection retry settings
buffer_config: BufferConfigBuffer sizes
Trait Implementations§
Source§impl Clone for TcpNetworkConfig
impl Clone for TcpNetworkConfig
Source§fn clone(&self) -> TcpNetworkConfig
fn clone(&self) -> TcpNetworkConfig
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 TcpNetworkConfig
impl Debug for TcpNetworkConfig
Source§impl Default for TcpNetworkConfig
impl Default for TcpNetworkConfig
Source§impl<'de> Deserialize<'de> for TcpNetworkConfig
impl<'de> Deserialize<'de> for TcpNetworkConfig
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 TcpNetworkConfig
impl RefUnwindSafe for TcpNetworkConfig
impl Send for TcpNetworkConfig
impl Sync for TcpNetworkConfig
impl Unpin for TcpNetworkConfig
impl UnsafeUnpin for TcpNetworkConfig
impl UnwindSafe for TcpNetworkConfig
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