File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -97,7 +97,7 @@ export type TriggerConfig = {
9797
9898 /**
9999 * Span processors to use for OpenTelemetry. This is useful if you want to add custom span processors to your tasks.
100- * There are executed in the order passed before running exporters
100+ * There are executed in the order passed before running exporters
101101 *
102102 * @see https://trigger.dev/docs/config/config-file#spanProcessors
103103 */
Original file line number Diff line number Diff line change @@ -85,7 +85,6 @@ export class TracingSDK {
8585 public readonly getTracer : TracerProvider [ "getTracer" ] ;
8686
8787 constructor ( private readonly config : TracingSDKConfig ) {
88- console . log ( "tracing sdk constructor called" ) ;
8988 setLogLevel ( config . diagLogLevel ?? "none" ) ;
9089
9190 const envResourceAttributesSerialized = getEnvVar ( "TRIGGER_OTEL_RESOURCE_ATTRIBUTES" ) ;
@@ -123,7 +122,7 @@ export class TracingSDK {
123122
124123 const spanProcessors : Array < SpanProcessor > = [ ] ;
125124
126- //add span processor passed via config before exporters
125+ //add span processor passed via config before adding exporters
127126 for ( const spanProcessor of config . spanProcessors ?? [ ] ) {
128127 spanProcessors . push ( spanProcessor ) ;
129128 }
@@ -147,8 +146,10 @@ export class TracingSDK {
147146 : new SimpleSpanProcessor ( spanExporter )
148147 )
149148 ) ;
149+
150150 const externalTraceId = idGenerator . generateTraceId ( ) ;
151151 const externalTraceContext = traceContext . getExternalTraceContext ( ) ;
152+
152153 for ( const exporter of config . exporters ?? [ ] ) {
153154 spanProcessors . push (
154155 getEnvVar ( "TRIGGER_OTEL_BATCH_PROCESSING_ENABLED" ) === "1"
You can’t perform that action at this time.
0 commit comments