observability.exporter.dfw_exporter#
Attributes#
Classes#
Processor that batches dictionary objects for bulk operations. |
|
Abstract base class for Data Flywheel exporters. |
Module Contents#
- logger#
- class DictBatchingProcessor#
Bases:
nat.observability.processor.batching_processor.BatchingProcessor[dict]Processor that batches dictionary objects for bulk operations.
Specializes BatchingProcessor with explicit dict typing to support bulk export operations to sinks.
- class DFWExporter(
- export_contract: type[pydantic.BaseModel],
- context_state: nat.builder.context.ContextState | None = None,
- batch_size: int = 100,
- flush_interval: float = 5.0,
- max_queue_size: int = 1000,
- drop_on_overflow: bool = False,
- shutdown_timeout: float = 10.0,
- client_id: str = 'default',
Bases:
nat.observability.exporter.span_exporter.SpanExporter[nat.data_models.span.Span,dict]Abstract base class for Data Flywheel exporters.
Initialize the Data Flywheel exporter.
- Args:
export_contract: The Pydantic model type for the export contract. context_state: The context state to use for the exporter. batch_size: The batch size for exporting spans. flush_interval: The flush interval in seconds for exporting spans. max_queue_size: The maximum queue size for exporting spans. drop_on_overflow: Whether to drop spans on overflow. shutdown_timeout: The shutdown timeout in seconds. client_id: The client ID for the exporter.
- _export_contract#
- property export_contract: type[pydantic.BaseModel]#
The export contract used for processing spans before converting to dict.
This type defines the structure of records that spans are converted to before being serialized to dictionaries for export.
- Returns:
type[BaseModel]: The Pydantic model type for the export contract.