fix: remove CloseFrame delay (#6106)

This commit is contained in:
Loakesh Indiran
2025-02-26 10:05:51 +05:30
committed by GitHub
parent f93b05cdb5
commit dccc130b3a
2 changed files with 0 additions and 13 deletions
@@ -347,17 +347,6 @@ async fn cleanup_and_close_session(req_id: &str, close_reason: Option<CloseReaso
);
}
#[cfg(feature = "enterprise")]
{
// sleep for the interval duration in milliseconds to avoid race condition
// between the close frame (control frame) and the data frame
let cfg = get_config();
let interval = cfg.websocket.close_frame_delay;
if interval > 0 {
tokio::time::sleep(std::time::Duration::from_millis(interval)).await;
}
}
// Attempt to close the session
if let Err(e) = session.close(close_reason).await {
log::error!(