mirror of
https://github.com/fluencelabs/rust-libp2p
synced 2025-06-25 15:51:34 +00:00
feat(swarm): deprecated keep_alive_timeout
from OneShotHandlerConfig
Related: #3844. Related: #4677 Pull-Request: #4680.
This commit is contained in:
@ -233,6 +233,9 @@ where
|
||||
#[derive(Debug)]
|
||||
pub struct OneShotHandlerConfig {
|
||||
/// Keep-alive timeout for idle connections.
|
||||
#[deprecated(
|
||||
note = "Set a global idle connection timeout via `SwarmBuilder::idle_connection_timeout` instead."
|
||||
)]
|
||||
pub keep_alive_timeout: Duration,
|
||||
/// Timeout for outbound substream upgrades.
|
||||
pub outbound_substream_timeout: Duration,
|
||||
@ -241,6 +244,7 @@ pub struct OneShotHandlerConfig {
|
||||
}
|
||||
|
||||
impl Default for OneShotHandlerConfig {
|
||||
#[allow(deprecated)]
|
||||
fn default() -> Self {
|
||||
OneShotHandlerConfig {
|
||||
keep_alive_timeout: Duration::from_secs(10),
|
||||
|
Reference in New Issue
Block a user