diff --git a/services/identity/src/grpc_services/shared.rs b/services/identity/src/grpc_services/shared.rs --- a/services/identity/src/grpc_services/shared.rs +++ b/services/identity/src/grpc_services/shared.rs @@ -1,6 +1,6 @@ use grpc_clients::error::unsupported_version; -use tonic::{Request, Status}; -use tracing::trace; +use tonic::{IntoRequest, Request, Status}; +use tracing::{trace, Instrument}; use crate::constants::{request_metadata, MIN_SUPPORTED_NATIVE_VERSION}; diff --git a/services/identity/src/main.rs b/services/identity/src/main.rs --- a/services/identity/src/main.rs +++ b/services/identity/src/main.rs @@ -90,6 +90,12 @@ .accept_http1(true) .layer(cors_layer()) .layer(GrpcWebLayer::new()) + .trace_fn(|_| { + tracing::info_span!( + "grpc_request", + request_id = uuid::Uuid::new_v4().to_string() + ) + }) .add_service(client_service) .add_service(auth_service) .serve(addr);