For the complete documentation index, see llms.txt. Markdown versions of all docs pages are available by appending .md to any docs URL.
OpenTelemetry Collector (OTel)
Route agentgateway traces through an OpenTelemetry Collector to fan out to multiple backends or apply processing pipelines.
The OpenTelemetry Collector is a vendor-agnostic proxy that receives, processes, and exports telemetry data. For production deployments, routing agentgateway traces through a collector lets you fan out to multiple backends, apply processing pipelines such as batching or filtering, and swap backends without changing your agentgateway configuration.
The way you set up the OTel Collector depends on how you installed agentgateway.
Run the OTel Collector as a Docker container on the same host as agentgateway and point agentgateway at localhost:4317.
Create an
otel-collector-config.yamlfile that defines the OTLP receiver, a batch processor, and your chosen exporter.receivers: otlp: protocols: grpc: endpoint: 0.0.0.0:4317 processors: batch: exporters: debug: verbosity: detailed service: pipelines: traces: receivers: [otlp] processors: [batch] exporters: [debug]Replace the
debugexporter with the exporter for your tracing backend. For a full example that exports to Jaeger, see the otel-collector-config.yaml file.Start the OTel Collector container and mount your config file.
docker run -d --name otel-collector \ -p 4317:4317 \ -v $(pwd)/otel-collector-config.yaml:/etc/otelcol/config.yaml \ otel/opentelemetry-collector:latestConfigure agentgateway to send traces to the collector.
# yaml-language-server: $schema=https://agentgateway.dev/schema/config frontendPolicies: tracing: host: localhost:4317 randomSampling: trueWhen you are done, remove the OTel Collector container.
docker rm -f otel-collector