aboutsummaryrefslogtreecommitdiff
path: root/src/client.rs
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2022-09-01 14:23:10 +0200
committerAlex Auvolat <alex@adnab.me>2022-09-01 14:23:10 +0200
commit22d96929d5416750e1f5889ee6cc16b382293104 (patch)
tree7b9407132ffa02fa5c7e9f6040f90f0e071b4bf3 /src/client.rs
parent4a59b73d7bfd0f136f654e874afb5d2a9bf4df2e (diff)
parentd75146fb8157dd03c156e5f7ce4834fa1d72b581 (diff)
downloadnetapp-22d96929d5416750e1f5889ee6cc16b382293104.tar.gz
netapp-22d96929d5416750e1f5889ee6cc16b382293104.zip
Merge branch 'fix-ping' into stream-body
Diffstat (limited to 'src/client.rs')
-rw-r--r--src/client.rs7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/client.rs b/src/client.rs
index df54810..9726125 100644
--- a/src/client.rs
+++ b/src/client.rs
@@ -100,13 +100,16 @@ impl ClientConn {
netapp.connected_as_client(peer_id, conn.clone());
+ let debug_name = format!("CLI {}", hex::encode(&peer_id[..8]));
+
tokio::spawn(async move {
- let send_future = tokio::spawn(conn.clone().send_loop(query_recv, write));
+ let debug_name_2 = debug_name.clone();
+ let send_future = tokio::spawn(conn.clone().send_loop(query_recv, write, debug_name_2));
let conn2 = conn.clone();
let recv_future = tokio::spawn(async move {
select! {
- r = conn2.recv_loop(read) => r,
+ r = conn2.recv_loop(read, debug_name) => r,
_ = await_exit(stop_recv_loop_recv) => Ok(())
}
});