1
0

throttle down client re-connect retries

This commit is contained in:
EAimTY 2022-07-03 17:18:31 +09:00
parent e986945e4e
commit 4268bd6037

View File

@ -51,6 +51,10 @@ pub async fn manage_connection(
Ok(conn) => conn,
Err(err) => {
log::error!("[relay] [connection] {err}");
// sleep 1 second to avoid drawing too much CPU
time::sleep(Duration::from_secs(1)).await;
continue;
}
};