diff --git a/proxy/src/http/websocket.rs b/proxy/src/http/websocket.rs index 5b7a87bc11..4b6e15dc3a 100644 --- a/proxy/src/http/websocket.rs +++ b/proxy/src/http/websocket.rs @@ -181,13 +181,15 @@ async fn ws_handler( // Check if the request is a websocket upgrade request. if hyper_tungstenite::is_upgrade_request(&request) { + info!(session_id = ?session_id, "performing websocket upgrade"); + let (response, websocket) = hyper_tungstenite::upgrade(&mut request, None) .map_err(|e| ApiError::BadRequest(e.into()))?; tokio::spawn(async move { if let Err(e) = serve_websocket(websocket, config, &cancel_map, session_id, host).await { - error!("error in websocket connection: {e:?}"); + error!(session_id = ?session_id, "error in websocket connection: {e:?}"); } }); diff --git a/proxy/src/proxy.rs b/proxy/src/proxy.rs index 2cdd1582ac..e37e7dc44b 100644 --- a/proxy/src/proxy.rs +++ b/proxy/src/proxy.rs @@ -196,6 +196,11 @@ pub async fn handle_client( stream: S, mode: ClientMode, ) -> anyhow::Result<()> { + info!( + protocol = mode.protocol_label(), + "handling interactive connection from client" + ); + // The `closed` counter will increase when this future is destroyed. NUM_CONNECTIONS_ACCEPTED_COUNTER .with_label_values(&[mode.protocol_label()])