refactor: connection handling timeout
This commit is contained in:
parent
7645830c77
commit
8c0bbf17e2
6 changed files with 34 additions and 33 deletions
|
|
@ -176,9 +176,9 @@ impl TryInto<ProxyConfig> for &ConfigToml {
|
|||
|
||||
if let Some(timeout) = exp.connection_handling_timeout {
|
||||
if timeout == 0u64 {
|
||||
proxy_config.connection_handling_timeout = Duration::from_secs(u64::MAX);
|
||||
proxy_config.connection_handling_timeout = None;
|
||||
} else {
|
||||
proxy_config.connection_handling_timeout = Duration::from_secs(timeout);
|
||||
proxy_config.connection_handling_timeout = Some(Duration::from_secs(timeout));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue