commit with debug code

This commit is contained in:
John Smith
2022-08-20 17:08:48 -04:00
parent 126bf28070
commit 53ae04aff9
3 changed files with 93 additions and 65 deletions

View File

@@ -88,6 +88,7 @@ struct RPCMessageEncoded {
data: RPCMessageData,
}
#[derive(Debug)]
pub(crate) struct RPCMessage {
header: RPCMessageHeader,
operation: RPCOperation,
@@ -336,7 +337,10 @@ impl RPCProcessor {
inner
.waiting_rpc_table
.remove(&op_id)
.ok_or_else(RPCError::else_internal("Unmatched operation id"))?
.ok_or_else(RPCError::else_internal(format!(
"Unmatched operation id: {:#?}",
msg
)))?
};
eventual.resolve((Span::current().id(), msg)).await;
Ok(())

View File

@@ -70,6 +70,9 @@ impl RPCProcessor {
SendDataKind::Indirect => {
// Do nothing in this case, as the socket address returned here would be for any node other than ours
}
SendDataKind::Existing(_) => {
// Do nothing in this case, as an existing connection could not have a different public address or it would have been reset
}
}
}