08 May 2025
12:53 AM
- last edited on
08 May 2025
08:46 AM
by
MaciejNeumann
I attempted to add the "Kubernetes Namespace" entity (dt.entity.cloud_application_namespace) for metric configuration, but the implementation is not working as expected.
builtin:containers.cpu.usagePercent:filter(in("dt.entity.container_group_instance",entitySelector("type(container_group_instance),fromRelationship.isCgiOfNamespace(type(CLOUD_APPLICATION_NAMESPACE))"))):splitBy("dt.entity.container_group_instance"):sort(value(auto,descending))
builtin:containers.memory.usagePercent:filter(in("dt.entity.container_group_instance",entitySelector("type(container_group_instance),fromRelationship.isCgiOfNamespace(type(CLOUD_APPLICATION_NAMESPACE))"))):splitBy("dt.entity.container_group_instance"):sort(value(auto,descending))
08 May 2025 01:41 AM
@Subhash It could be because below are the only dimensions that are available by default to split the metric
More flexibility would be available via DQL/Grail but unfortunately associated Grail metrics does not seem to be available for these at this time.
You can still be able to query other relevant metrics CPU (Millicore) and split by namespace in DQL if you are interested
timeseries avg(dt.kubernetes.container.cpu_usage), by:{k8s.namespace.name}
08 May 2025 02:15 AM
I am getting No metric found using the Metric Id "dt.kubernetes.container.cpu_usage".
08 May 2025 04:55 AM
@Subhash That's a DQL query, you would need to run it in a Notebook