Debug
This commit is contained in:
parent
27dcd62e1f
commit
66b9850ed6
1 changed files with 3 additions and 0 deletions
|
|
@ -203,6 +203,7 @@ impl Handler {
|
||||||
.await;
|
.await;
|
||||||
}
|
}
|
||||||
ClientFrames::WantHeartbeat { interval } => {
|
ClientFrames::WantHeartbeat { interval } => {
|
||||||
|
info!("Receive hearbet request with interval {interval}");
|
||||||
if interval > 0 {
|
if interval > 0 {
|
||||||
tokio::spawn(async move {
|
tokio::spawn(async move {
|
||||||
let mut heartbeat = Heartbeat::new(interval, send_message.clone());
|
let mut heartbeat = Heartbeat::new(interval, send_message.clone());
|
||||||
|
|
@ -211,6 +212,7 @@ impl Handler {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ClientFrames::IAmCamera { road, mile, limit } => {
|
ClientFrames::IAmCamera { road, mile, limit } => {
|
||||||
|
info!("Receive new camera {road} {mile} {limit}");
|
||||||
if self.connection_type.is_some() {
|
if self.connection_type.is_some() {
|
||||||
return Err("Already connected".into());
|
return Err("Already connected".into());
|
||||||
}
|
}
|
||||||
|
|
@ -227,6 +229,7 @@ impl Handler {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
ClientFrames::IAmDispatcher { roads } => {
|
ClientFrames::IAmDispatcher { roads } => {
|
||||||
|
info!("Receive new dispatcher {roads:?}");
|
||||||
if self.connection_type.is_some() {
|
if self.connection_type.is_some() {
|
||||||
return Err("Already connected".into());
|
return Err("Already connected".into());
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue