forked from lx/netapp
Fix span kind for RPC client side
This commit is contained in:
parent
b1425230cc
commit
faecefc7a8
3 changed files with 3 additions and 3 deletions
2
Cargo.lock
generated
2
Cargo.lock
generated
|
@ -433,7 +433,7 @@ dependencies = [
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "netapp"
|
name = "netapp"
|
||||||
version = "0.4.0"
|
version = "0.4.1"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"arc-swap",
|
"arc-swap",
|
||||||
"async-trait",
|
"async-trait",
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
[package]
|
[package]
|
||||||
name = "netapp"
|
name = "netapp"
|
||||||
version = "0.4.1"
|
version = "0.4.2"
|
||||||
authors = ["Alex Auvolat <alex@adnab.me>"]
|
authors = ["Alex Auvolat <alex@adnab.me>"]
|
||||||
edition = "2018"
|
edition = "2018"
|
||||||
license-file = "LICENSE"
|
license-file = "LICENSE"
|
||||||
|
|
|
@ -156,7 +156,7 @@ impl ClientConn {
|
||||||
if #[cfg(feature = "telemetry")] {
|
if #[cfg(feature = "telemetry")] {
|
||||||
let tracer = opentelemetry::global::tracer("netapp");
|
let tracer = opentelemetry::global::tracer("netapp");
|
||||||
let mut span = tracer.span_builder(format!("RPC >> {}", path))
|
let mut span = tracer.span_builder(format!("RPC >> {}", path))
|
||||||
.with_kind(SpanKind::Server)
|
.with_kind(SpanKind::Client)
|
||||||
.start(&tracer);
|
.start(&tracer);
|
||||||
let propagator = BinaryPropagator::new();
|
let propagator = BinaryPropagator::new();
|
||||||
let telemetry_id = Some(propagator.to_bytes(span.span_context()).to_vec());
|
let telemetry_id = Some(propagator.to_bytes(span.span_context()).to_vec());
|
||||||
|
|
Loading…
Reference in a new issue