remove debugging code
This commit is contained in:
parent
8878817961
commit
d160344a77
@ -185,11 +185,6 @@ impl ConnectionManager {
|
||||
// Connection already exists
|
||||
let desc = conn.connection_descriptor();
|
||||
let _ = inner.sender.send(ConnectionManagerEvent::Dead(conn));
|
||||
// xxx remove this
|
||||
panic!(
|
||||
"connection already exists: {:?} connection_table: {:#?}",
|
||||
desc, self.arc.connection_table
|
||||
);
|
||||
return Ok(NetworkResult::no_connection_other(format!(
|
||||
"connection already exists: {:?}",
|
||||
desc
|
||||
|
@ -1314,14 +1314,14 @@ impl NetworkManager {
|
||||
) -> SendPinBoxFuture<EyreResult<NetworkResult<SendDataKind>>> {
|
||||
let this = self.clone();
|
||||
Box::pin(async move {
|
||||
info!("{}", format!("send_data to: {:?}", node_ref).red());
|
||||
// info!("{}", format!("send_data to: {:?}", node_ref).red());
|
||||
|
||||
// First try to send data to the last socket we've seen this peer on
|
||||
let data = if let Some(connection_descriptor) = node_ref.last_connection() {
|
||||
info!(
|
||||
"{}",
|
||||
format!("last_connection to: {:?}", connection_descriptor).red()
|
||||
);
|
||||
// info!(
|
||||
// "{}",
|
||||
// format!("last_connection to: {:?}", connection_descriptor).red()
|
||||
// );
|
||||
|
||||
match this
|
||||
.net()
|
||||
@ -1329,11 +1329,11 @@ impl NetworkManager {
|
||||
.await?
|
||||
{
|
||||
None => {
|
||||
info!(
|
||||
"{}",
|
||||
format!("sent to existing connection: {:?}", connection_descriptor)
|
||||
.red()
|
||||
);
|
||||
// info!(
|
||||
// "{}",
|
||||
// format!("sent to existing connection: {:?}", connection_descriptor)
|
||||
// .red()
|
||||
// );
|
||||
|
||||
// Update timestamp for this last connection since we just sent to it
|
||||
node_ref.set_last_connection(connection_descriptor, intf::get_timestamp());
|
||||
@ -1348,7 +1348,7 @@ impl NetworkManager {
|
||||
data
|
||||
};
|
||||
|
||||
info!("{}", "no existing connection".red());
|
||||
// info!("{}", "no existing connection".red());
|
||||
|
||||
// If we don't have last_connection, try to reach out to the peer via its dial info
|
||||
let contact_method = this.get_contact_method(node_ref.clone());
|
||||
|
Loading…
Reference in New Issue
Block a user