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

Switch k8s metrics (container, pod, node, namespace) to use pdata. #23423

Conversation

atoulme
Copy link
Contributor

@atoulme atoulme commented Jun 16, 2023

Description:
Switch k8s metrics (container, pod, node, namespace) to use pdata.

@atoulme atoulme requested a review from a team June 16, 2023 07:12
@atoulme atoulme requested a review from dmitryax as a code owner June 16, 2023 07:12
@atoulme atoulme force-pushed the move_container_pod_namespace_node_to_pdata branch from f912820 to 33269fe Compare June 16, 2023 07:13
@atoulme atoulme force-pushed the move_container_pod_namespace_node_to_pdata branch from 33269fe to b2038d5 Compare June 16, 2023 07:16
@atoulme atoulme force-pushed the move_container_pod_namespace_node_to_pdata branch from b2038d5 to 21f2e3d Compare June 16, 2023 07:23
@atoulme atoulme force-pushed the move_container_pod_namespace_node_to_pdata branch from e279ee2 to 3d71e9a Compare June 16, 2023 07:46
Comment on lines +38 to +39
mb.RecordK8sContainerCPURequestDataPoint(ts, float64(c.Resources.Requests.Cpu().MilliValue())/1000.0)
mb.RecordK8sContainerCPULimitDataPoint(ts, float64(c.Resources.Limits.Cpu().MilliValue())/1000.0)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We miss k8s.container.memory_request and k8s.container.memory_limit now

case corev1.ResourceMemory:
mb.RecordK8sNodeAllocatableMemoryDataPoint(ts, quantity.Value())
case corev1.ResourceEphemeralStorage:
mb.RecordK8sNodeAllocatableEphemeralStorageDataPoint(ts, quantity.Value())
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

storage type is missed here

@dmitryax
Copy link
Member

Maybe better split them as before?

@atoulme
Copy link
Contributor Author

atoulme commented Jun 17, 2023

Splitting in #23438 and #23437 for node and namespace respectively. I cannot split container and pod as easily.

@atoulme atoulme closed this Jun 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants