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

[exporter/elasticsearch] deprecate/remove dedot config #33772

Open
axw opened this issue Jun 26, 2024 · 5 comments
Open

[exporter/elasticsearch] deprecate/remove dedot config #33772

axw opened this issue Jun 26, 2024 · 5 comments

Comments

@axw
Copy link
Contributor

axw commented Jun 26, 2024

Component(s)

exporter/elasticsearch

Describe the issue you're reporting

The dedot config was introduced in the initial implementation of the Elasticsearch exporter for expanding dotted attributes into JSON object hierarchies, merging objects as needed. e.g. "service.name": "svc" and "service.version": "1.0.0" would be combined into {"service": {"name": "svc", "version": "1.0.0"}}.

Somewhere along the line the exporter grew multiple encodings ("modes"): "none", "raw", and "ecs". Raw and None are almost the same, with some minor differences to how record-level attributes are encoded: at the top level vs. embedded under "Attributes."

ECS (Elastic Common Schema) mode came along more recently, with the intention being to encode Elasticsearch documents so they are compatible with existing Kibana UIs, dashboards, Ingest pipelines, etc. that expect ECS. Ingest pipelines in particular expect the documents to be "dedotted", so I think makes sense to always dedot in this mode, and remove the configuration.

Conversely, there's no real need to dedot in the exporter when using "none" or "raw" encodings. Dotted fields are understood by Elasticsearch, and the main reason for dedotting is to simplify Ingest pipelines. If you even need Ingest pipelines (why? use OTel Collector processors!) then you can instead use the dot_expander Ingest processor, or configure your Ingest processors to expect dotted field names.

All that to say: the dedot logic is making the exporter's encoding logic needlessly complicated. I propose we:

  • deprecate and then remove the dedot config
  • always dedot in ECS mode
  • never dedot in raw/none modes
@axw axw added the needs triage New item requiring triage label Jun 26, 2024
Copy link
Contributor

Pinging code owners:

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

andrzej-stencel pushed a commit that referenced this issue Jun 28, 2024
**Description:**

Deprecate `exporter/elasticsearch`'s "dedot" configuration. In a future
release we will remove this configuration, and always dedot ECS mode,
never for raw/none modes.

**Link to tracking Issue:**


#33772

**Testing:**

N/A

**Documentation:**

Updated the README.
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.

Pinging code owners:

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

@axw
Copy link
Contributor Author

axw commented Sep 4, 2024

This is still relevant. The code has been deprecated but not removed - we're waiting for the 6 month grace period per https://github.com/open-telemetry/opentelemetry-collector/blob/main/CONTRIBUTING.md

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.

Pinging code owners:

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

@github-actions github-actions bot added the Stale label Dec 11, 2024
@axw
Copy link
Contributor Author

axw commented Dec 11, 2024

Still relevant, see #33772 (comment)

@github-actions github-actions bot removed the Stale label Dec 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants