aboutsummaryrefslogtreecommitdiff
path: root/src/server.rs
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2022-07-25 15:04:52 +0200
committerAlex Auvolat <alex@adnab.me>2022-07-25 15:04:52 +0200
commit74e57016f63b6052cf6d539812859c3a46138eee (patch)
tree9e0dd9a7176d8f977b0dac55242c2870966ee90a /src/server.rs
parent7499721a10d1d9e977024224b9d80d91ce93628b (diff)
downloadnetapp-74e57016f63b6052cf6d539812859c3a46138eee.tar.gz
netapp-74e57016f63b6052cf6d539812859c3a46138eee.zip
Add some debugging
Diffstat (limited to 'src/server.rs')
-rw-r--r--src/server.rs7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/server.rs b/src/server.rs
index 4b232af..57062d8 100644
--- a/src/server.rs
+++ b/src/server.rs
@@ -3,7 +3,7 @@ use std::sync::Arc;
use arc_swap::ArcSwapOption;
use async_trait::async_trait;
-use log::{debug, trace};
+use log::*;
use futures::io::{AsyncReadExt, AsyncWriteExt};
use kuska_handshake::async_std::{handshake_server, BoxStream};
@@ -175,7 +175,8 @@ impl RecvLoop for ServerConn {
let self2 = self.clone();
tokio::spawn(async move {
- trace!("ServerConn recv_handler {}", id);
+ debug!("server: recv_handler got {}", id);
+
let (prio, resp_enc) = match ReqEnc::decode(stream).await {
Ok(req_enc) => {
let prio = req_enc.prio;
@@ -192,7 +193,7 @@ impl RecvLoop for ServerConn {
Err(e) => (PRIO_NORMAL, RespEnc::from_err(e)),
};
- trace!("ServerConn sending response to {}: ", id);
+ debug!("server: sending response to {}", id);
resp_send
.send((id, prio, resp_enc.encode()))