UNPKG

autotel

Version:
28 lines (27 loc) 799 B
// src/tail-sampling-processor.ts var TailSamplingSpanProcessor = class { wrappedProcessor; constructor(wrappedProcessor) { this.wrappedProcessor = wrappedProcessor; } onStart(span, parentContext) { this.wrappedProcessor.onStart(span, parentContext); } onEnd(span) { const tailEvaluated = span.attributes["sampling.tail.evaluated"]; const shouldKeep = span.attributes["sampling.tail.keep"]; if (tailEvaluated === true && shouldKeep === false) { return; } this.wrappedProcessor.onEnd(span); } forceFlush() { return this.wrappedProcessor.forceFlush(); } shutdown() { return this.wrappedProcessor.shutdown(); } }; export { TailSamplingSpanProcessor }; //# sourceMappingURL=chunk-X4RMFFMR.js.map //# sourceMappingURL=chunk-X4RMFFMR.js.map