OpenTelemetry Collector
Forward traces to xScaler using the OpenTelemetry Collector over OTLP/HTTP. The collector can receive traces from any OTLP-compatible source and forward them with the correct credentials.
:::warning Required headers
Both headers must be present in the exporters.otlphttp/xscaler.headers block:
Authorization: "Bearer <token>"X-Scope-OrgID: "<tenant-id>":::
Configuration
Save the following as otel-collector-config.yaml:
receivers:
otlp:
protocols:
grpc:
endpoint: 0.0.0.0:4317
http:
endpoint: 0.0.0.0:4318
processors:
memory_limiter:
check_interval: 1s
limit_mib: 512
batch:
timeout: 10s
send_batch_size: 1000
resourcedetection:
detectors: [env, system]
timeout: 5s
exporters:
otlphttp/xscaler:
endpoint: https://euw1-01.t.xscalerlabs.com
headers:
Authorization: "Bearer <token>"
X-Scope-OrgID: "<tenant-id>"
compression: gzip
retry_on_failure:
enabled: true
initial_interval: 5s
max_interval: 30s
max_elapsed_time: 300s
sending_queue:
enabled: true
num_consumers: 10
queue_size: 5000
service:
pipelines:
traces:
receivers: [otlp]
processors: [memory_limiter, resourcedetection, batch]
exporters: [otlphttp/xscaler]
telemetry:
logs:
level: info
Key configuration notes
endpoint is the base host only
Set endpoint to https://euw1-01.t.xscalerlabs.com — do not append /otlp/v1/traces. The otlphttp exporter appends the correct path automatically.
Processor order matters
memory_limiter— shed load under memory pressureresourcedetection— enrich spans with host/cloud metadatabatch— buffer and flush in bulk; always last before the exporter
Send all three signals
To forward metrics, logs, and traces in one collector config:
exporters:
otlphttp/xscaler_metrics:
endpoint: https://euw1-01.m.xscalerlabs.com
headers:
Authorization: "Bearer <token>"
X-Scope-OrgID: "<tenant-id>"
compression: gzip
otlphttp/xscaler_logs:
endpoint: https://euw1-01.l.xscalerlabs.com
headers:
Authorization: "Bearer <token>"
X-Scope-OrgID: "<tenant-id>"
compression: gzip
otlphttp/xscaler_traces:
endpoint: https://euw1-01.t.xscalerlabs.com
headers:
Authorization: "Bearer <token>"
X-Scope-OrgID: "<tenant-id>"
compression: gzip
service:
pipelines:
metrics:
receivers: [otlp]
processors: [memory_limiter, resourcedetection, batch]
exporters: [otlphttp/xscaler_metrics]
logs:
receivers: [otlp]
processors: [memory_limiter, resourcedetection, batch]
exporters: [otlphttp/xscaler_logs]
traces:
receivers: [otlp]
processors: [memory_limiter, resourcedetection, batch]
exporters: [otlphttp/xscaler_traces]
Run with Docker
docker run --rm \
-v $(pwd)/otel-collector-config.yaml:/etc/otelcol-contrib/config.yaml \
-p 4317:4317 -p 4318:4318 \
otel/opentelemetry-collector-contrib:latest
Troubleshooting
Enable debug logging
service:
telemetry:
logs:
level: debug
Traces not arriving
- Look for
"failed to export"in collector logs — the line includes the HTTP status code. - Verify
endpointis the base host only:https://euw1-01.t.xscalerlabs.com(no path suffix). - Check both
AuthorizationandX-Scope-OrgIDare under theheadersblock.