-
Notifications
You must be signed in to change notification settings - Fork 10
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
split k8sattributes/ecs processor: do not add any extra metadata #46
split k8sattributes/ecs processor: do not add any extra metadata #46
Conversation
Signed-off-by: Tetiana Kravchenko <tetiana.kravchenko@elastic.co>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is also possible to fix this by updating es exporter to translate these fields to ecs. Do you prefer one fix over another?
Signed-off-by: Tetiana Kravchenko <tetiana.kravchenko@elastic.co>
@@ -697,6 +697,13 @@ collectors: | |||
name: k8s.pod.uid | |||
- sources: | |||
- from: connection | |||
extract: | |||
metadata: | |||
- "k8s.replicaset.name" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
note:
for those fields translation happens on the es exporter side:
- "k8s.namespace.name"
- "k8s.deployment.name"
- "k8s.node.name"
- "k8s.pod.name"
- "k8s.pod.uid"
those fields were removed in comparison to k8sattributes for otel mode:
- "k8s.pod.ip"
- "k8s.pod.start_time"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for that!
So clarification,
- "k8s.replicaset.name",
- "k8s.statefulset.name"
- "k8s.daemonset.name"
- "k8s.cronjob.name"
- "k8s.job.name"
will remain as is in the kubernetes.pod datastream. We dont have a unique naming convention, just saying !
The upstream es exporter fix is open-telemetry/opentelemetry-collector-contrib#36233 . When that is merged, this PR can be reverted. |
@tetianakravchenko Do we want to include this in the 8.16 release version? |
@rogercoll yes, merging of this PR will not make it included in 8.16? |
No, we need to manually merge main instead :( #47 |
What: create
k8sattributes/ecs
processor where not added extra metadata.Why: with the common for otel and ecs
k8sattributes
processor all docs (in ecs mode) contained those fields:those fields were not translated into the
kubernetes.*
field format (in opposite to fields likedeployment.name
,namespace
,node.name
,pod.name
andpod.uid
- that is defined here https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/57caf5f830369d3f4994f7563323c73d6842424a/exporter/elasticsearchexporter/model.go#L55-L59)this PR is to prevent adding fields in
k8s.*
format in ecs mode docs and to prevent error related to thek8s.pod.ip
field:Note: there still will be added
k8s.pod.start_time
attribute, because it enabled by default