From f03bea59a4eee068c4aff2c47ef85db5aaf435eb Mon Sep 17 00:00:00 2001 From: Alka Trivedi Date: Thu, 9 Jan 2025 12:24:22 +0530 Subject: [PATCH] refactor --- src/index.ts | 2 -- src/instrument.ts | 7 ------- 2 files changed, 9 deletions(-) diff --git a/src/index.ts b/src/index.ts index f0f88a801..9281484c9 100644 --- a/src/index.ts +++ b/src/index.ts @@ -85,7 +85,6 @@ import * as v1 from './v1'; import { ObservabilityOptions, ensureInitialContextManagerSet, - ensureContextPropagation, } from './instrument'; // eslint-disable-next-line @typescript-eslint/no-var-requires @@ -378,7 +377,6 @@ class Spanner extends GrpcService { this._observabilityOptions?.enableEndToEndTracing ); ensureInitialContextManagerSet(); - ensureContextPropagation(); } /** diff --git a/src/instrument.ts b/src/instrument.ts index 2c7998733..8cb6329f6 100644 --- a/src/instrument.ts +++ b/src/instrument.ts @@ -27,7 +27,6 @@ import { Span, SpanStatusCode, context, - propagation, trace, INVALID_SPAN_CONTEXT, ROOT_CONTEXT, @@ -121,14 +120,8 @@ function ensureInitialContextManagerSet() { } } -function ensureContextPropagation() { - propagation.setGlobalPropagator(new W3CTraceContextPropagator()); -} - export {ensureInitialContextManagerSet}; -export {ensureContextPropagation}; - /** * startTrace begins an active span in the current active context * and passes it back to the set callback function. Each span will