I would like to know how to get current or the last read metric value of CPU and memory usage of all pods.
I tried to call the hawkler endpoint. I went to the browser developer mode by hitting f12 and took this endpoint from list of calls that are made when metrics page of a pod is loaded.
https://metrics.mydev.abccomp.com/hakular/metrics/gauges/myservice%dfjlajdflk-lkejre-12112kljdfkl%2Fcpu%2Fusage_rate/data?bucketDuration=1mn&start=-1mn
However this will give me the cpu usage metrics for the last minute, for that particular pod. I am trying to see if there is a command or way exisits that will give me only the current snapshot of cpu usage and memory stats of all the pods collectively like below:
pod memory usage memory max cpu usage cpu max
pod1 0.4 mb 2.0 mb 20 m cores 25 m cores
pod2 1.5 mb 2.0 mb 25 m cores 25 m cores