influxdata / influxdata/telegraf
`kube_inventory` input plugin: add pod UID to `kubernetes_pod_container`
- Dominant language
- Go
- Stars
- 17.8k
- Forks
- 5.8k
- Avg merge
- 1d 20h
- Merged PRs (30d)
- 161
Description
### Use Case
In some cases, subsequent pods have the same name (e.g. when pods are only by a StatefulSet).
In these cases, the `kubernetes_pod_container` metric cannot indicate which one of the pods it is, as there's only a `pod_name` tag and no `pod_uid` tag.
### Expected behavior
Provide a `pod_uid` tag in `kubernetes_pod_container` metric.
### Actual behavior
No `pod_uid` tag.
### Additional info
Briefly looking at the plugin's code, it seems quite easy to do, so I'm willing to submit a PR for that if you accept the suggestion.
Contributor guide
Research direction
Start by locating the kube_inventory input plugin and the code that assembles the kubernetes_pod_container metric tags. Trace the pod metadata available there, then update the relevant metric coverage so the pod_uid tag is present and verify the plugin tests or metric output confirm it.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, kubernetes
- Domain
- observability-sre
- Issue type
- Feature
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 65/100