Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Otel exporter not working with Elasticsearch #34129

Open
harshalschaudhari opened this issue Jul 17, 2024 · 3 comments
Open

Otel exporter not working with Elasticsearch #34129

harshalschaudhari opened this issue Jul 17, 2024 · 3 comments
Labels
question Further information is requested Stale

Comments

@harshalschaudhari
Copy link

Component(s)

exporter/elasticsearch

What happened?

Description

The application generates traces that can be viewed in Jaeger. I attempted to configure the Otel collector to send these traces to Elasticsearch using various combinations within a Docker Compose setup, but encountered the following error:

"Error decoding 'exporters': Unknown type 'elasticsearch' for ID 'elasticsearch/trace' (valid values: [zipkin nop file opencensus prometheus prometheusremotewrite debug logging otlp otlphttp kafka])."

Steps to Reproduce

I have a Docker Compose application set up with Jaeger, Elasticsearch, and an OtelCollector. I've confirmed that all processes are functioning correctly except for the OtelCollector.

Below is the OtelCollector configuration I've used:

`receivers:
otlp:
protocols:
grpc:
http:

processors:
batch:

exporters:
elasticsearch/trace:
endpoints:
- "http://elasticsearch:9200/" # Elasticsearch service URL
trace_index: "otel-traces" # Index for traces

service:
pipelines:
traces:
receivers: [otlp]
processors: [batch]
exporters: [elasticsearch/trace]`

Expected Result

Elasticsearch index shows the traces in respective index.

Actual Result

Otel Collector Container stopped due to error "Error decoding 'exporters': Unknown type 'elasticsearch' for ID 'elasticsearch/trace' (valid values: [zipkin nop file opencensus prometheus prometheusremotewrite debug logging otlp otlphttp kafka])."

Collector version

0.104.0

Environment information

Environment

OS: (e.g., "Ubuntu 20.04")
Compiler(if manually compiled): (e.g., "go 14.2")

OpenTelemetry Collector configuration

receivers:
  otlp:
    protocols:
      grpc:
      http:

processors:
  batch:

exporters:  
  elasticsearch/trace:
    endpoints:
      - "http://elasticsearch:9200/"  # Elasticsearch service URL
    trace_index: "otel-traces"   # Index for traces

service:
  pipelines:
    traces:
      receivers: [otlp]
      processors: [batch]
      exporters: [elasticsearch/trace]

Log output

No response

Additional context

No response

@harshalschaudhari harshalschaudhari added bug Something isn't working needs triage New item requiring triage labels Jul 17, 2024
Copy link
Contributor

Pinging code owners:

See Adding Labels via Comments if you do not have permissions to add labels yourself.

@crobert-1
Copy link
Member

You need to reference the contrib docker image in your docker-compose.yaml file. Currently, it looks like it's referencing the core distribution, which only has a subset of exporters (and components in general). This will be the docker image to reference.

@crobert-1 crobert-1 added question Further information is requested and removed bug Something isn't working exporter/elasticsearch needs triage New item requiring triage labels Jul 17, 2024
Copy link
Contributor

This issue has been inactive for 60 days. It will be closed in 60 days if there is no activity. To ping code owners by adding a component label, see Adding Labels via Comments, or if you are unsure of which component this issue relates to, please ping @open-telemetry/collector-contrib-triagers. If this issue is still relevant, please ping the code owners or leave a comment explaining why it is still relevant. Otherwise, please close it.

@github-actions github-actions bot added the Stale label Sep 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested Stale
Projects
None yet
Development

No branches or pull requests

2 participants