Class BatchSpanProcessor.Worker

java.lang.Object
io.opentelemetry.sdk.trace.export.BatchSpanProcessor.Worker
All Implemented Interfaces:
Runnable
Enclosing class:
BatchSpanProcessor

private static final class BatchSpanProcessor.Worker extends Object implements Runnable
  • Field Details

    • processedSpansCounter

      private final LongCounter processedSpansCounter
    • droppedAttrs

      private final Attributes droppedAttrs
    • exportedAttrs

      private final Attributes exportedAttrs
    • spanExporter

      private final SpanExporter spanExporter
    • scheduleDelayNanos

      private final long scheduleDelayNanos
    • maxExportBatchSize

      private final int maxExportBatchSize
    • exporterTimeoutNanos

      private final long exporterTimeoutNanos
    • nextExportTime

      private long nextExportTime
    • queue

      private final Queue<ReadableSpan> queue
    • spansNeeded

      private final AtomicInteger spansNeeded
    • signal

      private final BlockingQueue<Boolean> signal
    • flushRequested

      private final AtomicReference<CompletableResultCode> flushRequested
    • continueWork

      private volatile boolean continueWork
    • batch

      private final ArrayList<SpanData> batch
  • Constructor Details

  • Method Details

    • addSpan

      private void addSpan(ReadableSpan span)
    • run

      public void run()
      Specified by:
      run in interface Runnable
    • flush

      private void flush()
    • updateNextExportTime

      private void updateNextExportTime()
    • shutdown

      private CompletableResultCode shutdown()
    • forceFlush

      private CompletableResultCode forceFlush()
    • exportCurrentBatch

      private void exportCurrentBatch()