Skip to content

[processor/k8s_attributes] Consider moving k8s.cluster.uid detection to the resource detection processor #38207

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

Closed
dmitryax opened this issue Feb 26, 2025 · 6 comments · Fixed by #38216
Labels
enhancement New feature or request help wanted Extra attention is needed processor/k8sattributes k8s Attributes processor processor/resourcedetection Resource detection processor

Comments

@dmitryax
Copy link
Member

dmitryax commented Feb 26, 2025

Component(s)

No response

Is your feature request related to a problem? Please describe.

It can be valuable to set k8s.cluster.uid resource attribute to all telemetry in a particular cluster. However, k8s attributes processor requires having a pod association to set even the attribute that is taken from the configured k8s api without using any pod information. This mode of applying attributes is better suited in the resource detection processor, not k8s attributes processor.

Describe the solution you'd like

The detector can be called k8scluster (we already have k8snode detector). Similarly we can add k8s.cluster.name in this detector as requested in #35116.

Describe alternatives you've considered

It's possible to also update the k8s attributes processor to set k8s.cluster.uid on all telemetry, but that goes against its main purpose.

@dmitryax dmitryax added enhancement New feature or request help wanted Extra attention is needed processor/k8sattributes k8s Attributes processor processor/resourcedetection Resource detection processor labels Feb 26, 2025
Copy link
Contributor

Pinging code owners for processor/resourcedetection: @Aneurysm9 @dashpole. See Adding Labels via Comments if you do not have permissions to add labels yourself. For example, comment '/label priority:p2 -needs-triaged' to set the priority and remove the needs-triaged label.

Copy link
Contributor

Pinging code owners for processor/k8sattributes: @dmitryax @fatsheep9146 @TylerHelmuth @ChrsMark. See Adding Labels via Comments if you do not have permissions to add labels yourself. For example, comment '/label priority:p2 -needs-triaged' to set the priority and remove the needs-triaged label.

@dehaansa
Copy link
Contributor

Issue #35116 was actually addressed in #35450 , so I think this issue would be proposing adding this resource attribute to the kubeadm detector.

@dmitryax
Copy link
Member Author

dmitryax commented Feb 26, 2025

@dehaansa, thanks for pointing to the PR. I missed that. Makes sense. k8s.cluster.uid can be added to the kubeadm detector I guess. I'd still prefer k8scluster name, but not sure it worth renaming now

@odubajDT
Copy link
Contributor

Hi, I would like to handle this issue if possible

@odubajDT
Copy link
Contributor

Prepared a PR #38216

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed processor/k8sattributes k8s Attributes processor processor/resourcedetection Resource detection processor
Projects
None yet
3 participants