Skip to content

Commit

Permalink
Do not set NoopSpanProcessor if no span processor is set
Browse files Browse the repository at this point in the history
  • Loading branch information
myrotvorets-team committed Sep 30, 2023
1 parent d2d0f7a commit 461219b
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions lib/index.mts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { processDetectorSync } from '@opentelemetry/resources';
import { NodeSDK, type NodeSDKConfiguration } from '@opentelemetry/sdk-node';
import { BatchSpanProcessor, NoopSpanProcessor, SimpleSpanProcessor } from '@opentelemetry/sdk-trace-base';
import { BatchSpanProcessor, SimpleSpanProcessor } from '@opentelemetry/sdk-trace-base';
import { ZipkinExporter } from '@opentelemetry/exporter-zipkin';
import {
dockerDetector,
Expand Down Expand Up @@ -28,8 +28,6 @@ export class OpenTelemetryConfigurator {
? new BatchSpanProcessor(this._config.traceExporter)
: new SimpleSpanProcessor(this._config.traceExporter);
/* c8 disable end */
} else {
this._config.spanProcessor = new NoopSpanProcessor();
}
}

Expand Down

0 comments on commit 461219b

Please sign in to comment.