> ## Documentation Index
> Fetch the complete documentation index at: https://agent-observability-docs.splunk.com/llms.txt
> Use this file to discover all available pages before exploring further.

# sink

## Module

SDK-owned batching lifecycle for completed OTel spans.

## BatchConfig

Configuration for the SDK-owned BatchSpanProcessor.

## SpanSink

SDK-owned abstraction over a batch processor and tracer provider.

### emit

```python theme={null}
def emit(self, span: ReadableSpan) -> None
```

Enqueue a completed span without flushing the batch.

### export\_health

```python theme={null}
def export_health(self) -> ExportHealth
```

Return the current receiver-acknowledgement health snapshot.

### force\_flush

```python theme={null}
def force_flush(self, timeout_millis: int=30000) -> bool
```

Drain all registered processors through the owned provider.

### shutdown

```python theme={null}
def shutdown(self) -> None
```

Shut down the owned provider exactly once.

## build\_batch\_processor

```python theme={null}
def build_batch_processor(exporter: SpanExporter,
                          config: BatchConfig | None=None) -> BatchSpanProcessor
```

Build a BatchSpanProcessor with explicit SDK defaults.

## build\_span\_sink

```python theme={null}
def build_span_sink(exporter: SpanExporter,
                    batch_config: BatchConfig | None=None) -> SpanSink
```

Build an SDK-owned sink without replacing the global tracer provider.
