Add more debugging printlns
This commit is contained in:
parent
a482a6ac18
commit
2322b6ae7f
1 changed files with 6 additions and 0 deletions
|
@ -64,6 +64,7 @@ async fn handle_conn(peer: SocketAddr, stream: TcpStream) -> tokio_tungstenite::
|
||||||
.map(char::from)
|
.map(char::from)
|
||||||
.collect();
|
.collect();
|
||||||
|
|
||||||
|
println!("HELLO to {}", &peer);
|
||||||
ws_sender.send(Message::Text(
|
ws_sender.send(Message::Text(
|
||||||
serde_json::to_string(
|
serde_json::to_string(
|
||||||
&SocketMessage {
|
&SocketMessage {
|
||||||
|
@ -88,14 +89,18 @@ async fn handle_conn(peer: SocketAddr, stream: TcpStream) -> tokio_tungstenite::
|
||||||
if op.is_ok() {
|
if op.is_ok() {
|
||||||
match op.unwrap().0 {
|
match op.unwrap().0 {
|
||||||
OpCode::IDENTIFY => {
|
OpCode::IDENTIFY => {
|
||||||
|
println!("IDENTIFY from {}", &peer);
|
||||||
unimplemented!()
|
unimplemented!()
|
||||||
}
|
}
|
||||||
|
|
||||||
OpCode::RESUME => {
|
OpCode::RESUME => {
|
||||||
|
println!("RESUME from {}", &peer);
|
||||||
unimplemented!()
|
unimplemented!()
|
||||||
}
|
}
|
||||||
|
|
||||||
OpCode::HEARTBEAT => {
|
OpCode::HEARTBEAT => {
|
||||||
|
println!("HEARTBEAT from {}", &peer);
|
||||||
|
println!("HEARTBEAT_ACK to {}", &peer);
|
||||||
ws_sender.send(Message::Text(
|
ws_sender.send(Message::Text(
|
||||||
serde_json::to_string(
|
serde_json::to_string(
|
||||||
&SocketMessage {
|
&SocketMessage {
|
||||||
|
@ -109,6 +114,7 @@ async fn handle_conn(peer: SocketAddr, stream: TcpStream) -> tokio_tungstenite::
|
||||||
}
|
}
|
||||||
|
|
||||||
OpCode::INFO => {
|
OpCode::INFO => {
|
||||||
|
println!("INFO from {}", &peer);
|
||||||
unimplemented!()
|
unimplemented!()
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue