receivers:
  otlp:
    protocols:
      grpc:
        endpoint: 0.0.0.0:4317

processors:
  memory_limiter:
    check_interval: 1s
    limit_percentage: 80
    spike_limit_percentage: 25
  # Drops any record whose resource lacks one of the three attributes every
  # dashboard and alert here groups by. A record is dropped when ANY condition
  # is true.
  filter/enforce-semconv:
    error_mode: ignore
    logs:
      log_record:
        - resource.attributes["service.name"] == nil
        - resource.attributes["service.namespace"] == nil
        - resource.attributes["deployment.environment.name"] == nil
    traces:
      span:
        - resource.attributes["service.name"] == nil
        - resource.attributes["service.namespace"] == nil
        - resource.attributes["deployment.environment.name"] == nil
    metrics:
      metric:
        - resource.attributes["service.name"] == nil
        - resource.attributes["service.namespace"] == nil
        - resource.attributes["deployment.environment.name"] == nil
  batch:
    timeout: 5s

exporters:
  otlphttp:
    endpoint: https://your-backend:4318

service:
  pipelines:
    logs:
      receivers: [otlp]
      processors: [memory_limiter, filter/enforce-semconv, batch]
      exporters: [otlphttp]
    traces:
      receivers: [otlp]
      processors: [memory_limiter, filter/enforce-semconv, batch]
      exporters: [otlphttp]
    metrics:
      receivers: [otlp]
      processors: [memory_limiter, filter/enforce-semconv, batch]
      exporters: [otlphttp]
