-
Notifications
You must be signed in to change notification settings - Fork 392
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
[Kubernetes] Add support for TSDB - set dimension fields for state data streams #5621
Conversation
🌐 Coverage report
|
@constanca-m why not the container.id? Isn't it unique across the cluster? |
- description: Add support for TSDB on all state metric data streams | ||
type: enhancement | ||
link: https://github.com/elastic/integrations/pull/5621 | ||
- version: "1.33.0" |
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.
Here, you should go with the 1.33.0 version. If the other commit gets merged first you will rebase/merge on this one and increment the version.
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.
I know, I chose it assuming the other one was being merged first. But I will adjust this if it is not case.
We just needed one set as dimension. I think they are both good and always available, there was no special reason to choose one over another. @MichaelKatsoulis |
I asked mainly because container.id had already dimension:true and you removed it. If we go with pod.uid then what happens if a pod has multiple containers. They will all have same pod.uid but different container.id |
You're right, I hadn't remember that. I checked, and |
Package kubernetes - 1.34.0 containing this change is available at https://epr.elastic.co/search?package=kubernetes |
What does this PR do?
Set the dimension fields for each state metric datastream. This is a follow up to the PR #5464.
Checklist
changelog.yml
file.Changes
The general reasons for this change can be found in #5464, as well as more information such as testing or
ecs
fields set as dimension.Specifically, for each data stream:
kubernetes.pod.uid
is a dimension, since it is unique across the whole cluster, as well askubernetes.container.id
. Every metric label is set as dimension (phase
andreason
) to avoid overlap on documents.kubernetes.cronjob.name
is set as dimension, along withkubernetes.namespace_uid
as the name is unique per namespace.kubernetes.daemonset.name
andkubernetes.namespace_uid
are dimensions.kubernetes.deployment.name
andkubernetes.namespace_uid
are dimensions.kubernetes.job.name
andkubernetes.namespace_uid
are dimensions. Note: other keyword fields insidefields.yaml
are not set as dimension, because thejob.name
is enough to uniquely identify the document.kubernetes.node.name
set as dimension, since it is always present and is unique across a cluster. Note: none of the keywords insidefields.yml
is set as dimension. This is because they were obtained through the method label metric that only stores values that are set to 1, so no overlap will happen.: kubernetes.persistentvolume.name
set as dimensionkubernetes.persistentvolumeclaim.name
set as dimension andkubernetes.namespace_uid
as well.kubernetes.pod.uid
set as dimension since it is unique. Note: none of the keywords insidefields.yml
is set as dimension, for the same reason as stated for state node.kubernetes.namespace_uid
andkubernetes.replicaset.name
are dimensions.kubernetes.namespace
(for the unique combination name + namespace) are set as dimension.kubernetes.namespace_uid
andkubernetes.service.name
are dimensions.kubernetes.namespace_uid
andkubernetes.statefulset.name
are dimensions.kubernetes.storageclass.name
is set as dimension.Screenshots
Before and after enabling TSDB, there was no change in the number of docs:
![image](https://user-images.githubusercontent.com/113898685/226677466-e476d55e-5b7c-4c1b-b691-7200763a7c77.png)