# Collector Contrib 0.136.0. Set OTEL_GATEWAY_IP to the intended private
# interface. Install server identity and sender trust roots before startup.
# Replace the illustrative backend names. OTLP exporters use TLS.
receivers:
  otlp:
    protocols:
      grpc:
        endpoint: ${env:OTEL_GATEWAY_IP}:4317
        tls:
          cert_file: /etc/otel/tls/server.crt
          key_file: /etc/otel/tls/server.key
          client_ca_file: /etc/otel/tls/agent-ca.crt
      http:
        endpoint: ${env:OTEL_GATEWAY_IP}:4318
        tls:
          cert_file: /etc/otel/tls/server.crt
          key_file: /etc/otel/tls/server.key
          client_ca_file: /etc/otel/tls/agent-ca.crt

processors:
  memory_limiter:
    check_interval: 1s
    limit_mib: 256
    spike_limit_mib: 64
  batch: {}

exporters:
  otlp/trace_primary:
    endpoint: trace-a.example.invalid:4317
  otlp/trace_secondary:
    endpoint: trace-b.example.invalid:4317
  otlp/metrics:
    endpoint: signals.example.invalid:4317
  otlp/logs:
    endpoint: signals.example.invalid:4317

service:
  pipelines:
    traces:
      receivers: [otlp]
      processors: [memory_limiter, batch]
      exporters: [otlp/trace_primary, otlp/trace_secondary]
    metrics:
      receivers: [otlp]
      processors: [memory_limiter, batch]
      exporters: [otlp/metrics]
    logs:
      receivers: [otlp]
      processors: [memory_limiter, batch]
      exporters: [otlp/logs]
