mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-29 03:17:56 +00:00
observability: tracing gum, automatically cross ref traceID (#5079)
* add some gum * bump expander * gum * fix all remaining issues * last fixup * Update node/gum/proc-macro/src/lib.rs Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com> * change * netowrk * fixins * chore * allow optional fmt str + args, prep for expr as kv field * tracing -> gum rename fallout * restrict further * allow multiple levels of field accesses * another round of docs and a slip of the pen * update ADR * fixup lock fiel * use target: instead of target= * minors * fix * chore * Update node/gum/README.md Co-authored-by: Andrei Sandu <54316454+sandreim@users.noreply.github.com> Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com> Co-authored-by: Andrei Sandu <54316454+sandreim@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
fa359fd1f7
commit
d631f1dea8
@@ -72,7 +72,7 @@ fn test_harness<T: Future<Output = VirtualOverseer>>(
|
||||
const TIMEOUT: Duration = Duration::from_millis(100);
|
||||
|
||||
async fn overseer_send(overseer: &mut VirtualOverseer, msg: ApprovalDistributionMessage) {
|
||||
tracing::trace!(msg = ?msg, "Sending message");
|
||||
gum::trace!(msg = ?msg, "Sending message");
|
||||
overseer
|
||||
.send(FromOverseer::Communication { msg })
|
||||
.timeout(TIMEOUT)
|
||||
@@ -81,7 +81,7 @@ async fn overseer_send(overseer: &mut VirtualOverseer, msg: ApprovalDistribution
|
||||
}
|
||||
|
||||
async fn overseer_signal_block_finalized(overseer: &mut VirtualOverseer, number: BlockNumber) {
|
||||
tracing::trace!(?number, "Sending a finalized signal");
|
||||
gum::trace!(?number, "Sending a finalized signal");
|
||||
// we don't care about the block hash
|
||||
overseer
|
||||
.send(FromOverseer::Signal(OverseerSignal::BlockFinalized(Hash::zero(), number)))
|
||||
@@ -91,10 +91,10 @@ async fn overseer_signal_block_finalized(overseer: &mut VirtualOverseer, number:
|
||||
}
|
||||
|
||||
async fn overseer_recv(overseer: &mut VirtualOverseer) -> AllMessages {
|
||||
tracing::trace!("Waiting for a message");
|
||||
gum::trace!("Waiting for a message");
|
||||
let msg = overseer.recv().timeout(TIMEOUT).await.expect("msg recv timeout");
|
||||
|
||||
tracing::trace!(msg = ?msg, "Received message");
|
||||
gum::trace!(msg = ?msg, "Received message");
|
||||
|
||||
msg
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user