From bd8037ac29c58d3e82c5860d337ca101b3d3ed9c Mon Sep 17 00:00:00 2001 From: Ertugrul Aypek Date: Sun, 29 Sep 2024 01:57:48 +0200 Subject: [PATCH] remove otel context --- iris-mpc-common/src/helpers/tracing.rs | 1 + iris-mpc/src/bin/server.rs | 9 ++------- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/iris-mpc-common/src/helpers/tracing.rs b/iris-mpc-common/src/helpers/tracing.rs index 3a86025dc..e9fed3251 100644 --- a/iris-mpc-common/src/helpers/tracing.rs +++ b/iris-mpc-common/src/helpers/tracing.rs @@ -25,5 +25,6 @@ pub fn trace_from_message_attributes(trace_id: &str, span_id: &str) -> eyre::Res .span_builder("mpcv2-batch-item") .start_with_context(&tracer, &parent_ctx); span.add_event("Created batch span item", vec![]); + tracing::info!("Created batch span item"); Ok(span.span_context().clone()) } diff --git a/iris-mpc/src/bin/server.rs b/iris-mpc/src/bin/server.rs index dbfd257a3..9e4d78b83 100644 --- a/iris-mpc/src/bin/server.rs +++ b/iris-mpc/src/bin/server.rs @@ -36,8 +36,7 @@ use iris_mpc_gpu::{ use iris_mpc_store::{Store, StoredIrisRef}; use opentelemetry::{ global::tracer, - trace::{Link, TraceContextExt, Tracer}, - Context as OtelContext, + trace::{Link, Tracer}, }; use std::{ collections::HashMap, @@ -55,7 +54,6 @@ use tokio::{ time::timeout, }; use tracing::Instrument; -use tracing_opentelemetry::OpenTelemetrySpanExt; use tracing_subscriber::{layer::SubscriberExt, util::SubscriberInitExt}; const REGION: &str = "eu-north-1"; @@ -922,14 +920,11 @@ async fn server_main(config: Config) -> eyre::Result<()> { links.len() ); - let batch_span = tracer + tracer .span_builder("batch_processing") .with_links(links) .start(&tracer); - let otel_context = OtelContext::current_with_span(batch_span); - tracing::Span::current().set_parent(otel_context); - process_identity_deletions( &batch, &store,