From 2377a92f6b64165be84f53722f30c21e9c8a0b3e Mon Sep 17 00:00:00 2001 From: Alex Auvolat Date: Thu, 24 Feb 2022 14:59:49 +0100 Subject: Add wrapper over sled tree to count items (used for big queues) --- src/rpc/rpc_helper.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/rpc') diff --git a/src/rpc/rpc_helper.rs b/src/rpc/rpc_helper.rs index 89225511..1b351024 100644 --- a/src/rpc/rpc_helper.rs +++ b/src/rpc/rpc_helper.rs @@ -134,7 +134,11 @@ impl RpcHelper { M: Rpc>, H: EndpointHandler, { - let metric_tags = [KeyValue::new("rpc_endpoint", endpoint.path().to_string())]; + let metric_tags = [ + KeyValue::new("rpc_endpoint", endpoint.path().to_string()), + KeyValue::new("from", format!("{:?}", self.0.our_node_id)), + KeyValue::new("to", format!("{:?}", to)), + ]; let msg_size = rmp_to_vec_all_named(&msg)?.len() as u32; let permit = self @@ -245,6 +249,7 @@ impl RpcHelper { ) }; let mut span = tracer.start(span_name); + span.set_attribute(KeyValue::new("from", format!("{:?}", self.0.our_node_id))); span.set_attribute(KeyValue::new("to", format!("{:?}", to))); span.set_attribute(KeyValue::new("quorum", quorum as i64)); span.set_attribute(KeyValue::new( -- cgit v1.2.3