more logging notes
This commit is contained in:
parent
5082438d6e
commit
a7cad3781d
1 changed files with 3 additions and 1 deletions
|
@ -51,7 +51,7 @@ pub async fn connect_to_server(
|
|||
let (to_core_sender, to_core_reciever) = async_channel::bounded::<ApplicationMessage>(MAX_MESSAGE);
|
||||
let (to_app_events, from_app_events) = async_channel::bounded::<ApplicationMessage>(MAX_MESSAGE);
|
||||
|
||||
debug!("created channels for oneshote");
|
||||
debug!("created channels for oneshot");
|
||||
|
||||
if let Err(e) = result_oneshot.send(Ok((to_core_sender as AppSender, from_app_events as AppReceiver))) {
|
||||
if let Err(e2) = ws.close(None).await {
|
||||
|
@ -61,6 +61,7 @@ pub async fn connect_to_server(
|
|||
return;
|
||||
}
|
||||
|
||||
debug!("splitting websocket!");
|
||||
let (ws_sender, ws_recv) = ws.split();
|
||||
|
||||
let receiver_is_closed = Arc::new(AtomicBool::new(false));
|
||||
|
@ -118,6 +119,7 @@ pub async fn send_to_wc_task(
|
|||
|
||||
}
|
||||
|
||||
info!("send_to_wc is closing!");
|
||||
let _ = sender.close().await;
|
||||
is_closed.store(true, std::sync::atomic::Ordering::SeqCst);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue