diff --git a/services/tunnelbroker/src/main.rs b/services/tunnelbroker/src/main.rs --- a/services/tunnelbroker/src/main.rs +++ b/services/tunnelbroker/src/main.rs @@ -158,11 +158,11 @@ ); tokio::select! { - Ok(_) = grpc_server => { Ok(()) }, - Ok(_) = websocket_server => { Ok(()) }, - else => { - tracing::error!(errorType = error_types::SERVER_ERROR, "A grpc or websocket server crashed."); - Err(anyhow!("A grpc or websocket server crashed.")) - } + grpc_result = grpc_server => { + grpc_result.map_err(|err| anyhow!("gRPC server failed: {:?}", err)) + }, + ws_result = websocket_server => { + ws_result.map_err(|err| anyhow!("WS server failed: {:?}", err)) + }, } }