fix(proxy): improve connection cleanup and route validation handling

This commit is contained in:
2026-03-25 07:22:17 +00:00
parent 34dc0cb9b6
commit 53dee1fffc
12 changed files with 689 additions and 623 deletions

View File

@@ -1209,8 +1209,10 @@ impl HttpProxyService {
};
tokio::spawn(async move {
if let Err(e) = conn.await {
debug!("Upstream connection error: {}", e);
match tokio::time::timeout(std::time::Duration::from_secs(300), conn).await {
Ok(Err(e)) => debug!("Upstream connection error: {}", e),
Err(_) => debug!("H1 connection driver timed out after 300s"),
_ => {}
}
});
@@ -1803,8 +1805,10 @@ impl HttpProxyService {
};
tokio::spawn(async move {
if let Err(e) = conn.await {
debug!("H1 fallback: upstream connection error: {}", e);
match tokio::time::timeout(std::time::Duration::from_secs(300), conn).await {
Ok(Err(e)) => debug!("H1 fallback: upstream connection error: {}", e),
Err(_) => debug!("H1 fallback: connection driver timed out after 300s"),
_ => {}
}
});