27 Jun 2021 07:50 PM
We want to help our application teams to optimize their pod resource management and reduce their resource slack.
Slack is the difference between resource requests and resource usage, e.g. requesting 2 GiB of memory and only using 200 MiB would mean 1.8 GiB of memory slack --- i.e. 1.8 GiB of memory capacity are blocked (and paid for), but unused. The same with cpu requests and usage.
So application teams should easily see for their pods if the ratio between resource request and resource usage is in an acceptable range or not.
how would you solve that with dynatrace?
Solved! Go to Solution.
28 Jun 2021 12:45 PM
Hello,
Soon enough you'll be able to do such simple arithmetic between metrics within the UI (using the Metrics explorer charts). For now you can explore an API-first version of this functionality:
https://www.dynatrace.com/support/help/dynatrace-api/environment-api/metric-v2/metric-expressions/
Best regards,
Radu
28 Jun 2021 01:11 PM - edited 29 Jun 2021 05:31 AM
Great to hear Radu!
In the meantime it would be perfectly fine if we can gather this data in a chart with the data explorer or custom charting.
However, I also struggle with the metrics and filters.
I used "container group instances: CPU usage mCores" and "Kubernetes Pods: CPU Requests" for this purpose. Are those the right metrics? It feels that there are lots of different "CPU usage" metrics but no explanation which one is which.
Also, in the custom-charting filter I can use "Kubernetes pods" also for the "container group instances". However, in the data explorer I can't fliter for "Kubernetes pods" in the "container group instances". Somehow confusing.