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/kafka] Logs with custom schema #12621

Closed
nanorobocop opened this issue Jul 21, 2022 · 6 comments
Closed

[exporter/kafka] Logs with custom schema #12621

nanorobocop opened this issue Jul 21, 2022 · 6 comments
Labels
closed as inactive enhancement New feature or request exporter/kafka priority:needed Triagers reviewed the issue but need code owner to set priority Stale

Comments

@nanorobocop
Copy link

Is your feature request related to a problem? Please describe.
We want to send logs to Kafka using our custom schema.
Kafka exporter sends logs in defined LogsData format.
In our case we already have predefined schema for logs in our storage, so we want to send logs using our own schema.
Currently Kafka exporter does not allows to modify schema.

Describe the solution you'd like
I'm thinking about several different approaches how to implement custom schema for kafka exporter:

  • Send only Attributes.
    • Attributes are dynamic map[string]Any fields, so would be easy to use.
  • Mapping Fields.
    • This is similar to Elasticsearch Fields. Those Fields will be added as top level fields of original record.

First approach is more generic I think.
It requires only attributes modification in standard opentelemetry-collector pipeline.

I'd like to hear what community thinks about it or if any other ideas.

Describe alternatives you've considered

Additional context

@mx-psi mx-psi added exporter/kafka enhancement New feature or request labels Jul 21, 2022
@github-actions
Copy link
Contributor

Pinging code owners: @pavolloffay @MovieStoreGuy

@nanorobocop
Copy link
Author

This is probably depends on #12623
Custom schema should be applied to individual records, not set of records.

@TylerHelmuth TylerHelmuth added the priority:needed Triagers reviewed the issue but need code owner to set priority label Jul 22, 2022
@MovieStoreGuy
Copy link
Contributor

I think this warrants a further discussion than just applying to the KafkaExporter since this could also apply to the Kinesis Exporter, FileExporter and I am sure more in future.

I need to think more about this because it also comes with a performance impact as well

@nanorobocop
Copy link
Author

Thanks for comment!

My implementation consists of 2 parts:

Custom schema implemented just by sending Attributes (which is dynamic map, could be constructed during Processing phase). So similar approach could be done in other exporters as well.

@github-actions
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 Nov 10, 2022
@github-actions
Copy link
Contributor

This issue has been closed as inactive because it has been stale for 120 days with no activity.

@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale May 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
closed as inactive enhancement New feature or request exporter/kafka priority:needed Triagers reviewed the issue but need code owner to set priority Stale
Projects
None yet
Development

No branches or pull requests

4 participants