I’m testing the AWS open telemetry collector for lambda/nodejs (aws-otel-nodejs-amd64-ver-1-0-1) using the following lambda layer: arn:aws:lambda:us-east-1:901920570463:layer:aws-otel-nodejs-amd64-ver-1-0-1:2.
I have opensearch/data-prepper deployed on an ec2 machine and use the aws opensearch managed service.
However, I don’t manage to get the traces into opensearch. I’ve tried 2 different configurations of the open telemetry collector.
Both give a (different) error message. What am I missing?
data-prepper config file:
entry-pipeline:
workers: 2
delay: "100"
source:
otel_trace_source:
ssl: false
health_check_service: true
sink:
- pipeline:
name: "raw-pipeline"
- pipeline:
name: "service-map-pipeline"
raw-pipeline:
workers: 2
source:
pipeline:
name: "entry-pipeline"
prepper:
- otel_trace_raw_prepper:
sink:
- opensearch:
hosts: [ "https://vpc-invxxxxxxxxxxxx6eiec3woa.us-east-1.es.amazonaws.com" ]
aws_sigv4: false
aws_region: "us-east-1"
username: "os-admin"
password: "xxxxxx"
trace_analytics_raw: true
service-map-pipeline:
workers: 2
delay: "100"
source:
pipeline:
name: "entry-pipeline"
prepper:
- service_map_stateful:
sink:
- opensearch:
hosts: [ "https://vpc-invxxxxxxxxxxxx6eiec3woa.us-east-1.es.amazonaws.com" ]
aws_sigv4: false
aws_region: "us-east-1"
username: "os-admin"
password: "xxxxxxx"
trace_analytics_service_map: true
First experiment (using otlp/http):
Otel config file:
receivers:
otlp:
protocols:
grpc:
http:
exporters:
otlphttp/data-prepper:
endpoint: "http://172.xx.xx.xx:4900"
tls:
insecure: true
service:
pipelines:
traces:
receivers: [otlp]
exporters: [otlphttp/data-prepper]
telemetry:
logs:
level: "debug"
Then I get a 404 error on the exporter side (found in cloudwatch)
2022-03-22T12:43:52.605Z debug otlphttpexporter/otlp.go:127 Preparing to make HTTP request {
"kind": "exporter",
"name": "otlphttp/data-prepper",
"url": "http://172.xx.xx.xx:4900/v1/traces"
}
2022-03-22T12:43:52.687Z info exporterhelper/queued_retry.go:215 Exporting failed. Will retry the request after interval. {
"kind": "exporter",
"name": "otlphttp/data-prepper",
"error": "error exporting items, request to http://172.xx.xx.xx:4900/v1/traces responded with HTTP Status Code 404",
"interval": "5.52330144s"
}
Second experiment (using grpc):
Otel config file:
receivers:
otlp:
protocols:
grpc:
http:
exporters:
otlp/data-prepper:
endpoint: "172.xx.xx.xx:4900"
tls:
insecure: true
service:
pipelines:
traces:
receivers: [otlp]
exporters: [otlp/data-prepper]
telemetry:
logs:
level: "debug"
Then I get the following error on the exporter side (cloudwatch):
2022-03-22T12:54:56.595Z info exporterhelper/queued_retry.go:215 Exporting failed. Will retry the request after interval. {
"kind": "exporter",
"name": "otlp/data-prepper",
"error": "rpc error: code = Unavailable desc = connection closed before server preface received",
"interval": "5.822800266s"
}