云容器实例 CCI-获取指定namespace下指定pod的metrics信息:响应示例

时间:2023-12-01 17:06:33

响应示例

状态码: 200

OK

{
  "apiVersion" : "metrics.k8s.io/v1beta1",
  "containers" : [ {
    "name" : "container-0",
    "usage" : {
      "cpu" : "353450n",
      "cpu_accumulated" : "127810375798n",
      "memory" : "1560Ki",
      "memory_rss" : "284Ki",
      "memory_usage" : "1824Ki"
    }
  } ],
  "kind" : "PodMetrics",
  "metadata" : {
    "creationTimestamp" : "2023-03-28T11:28:23Z",
    "name" : "cci-deployment-20233231-6c8d7f74f7-2t6k5",
    "namespace" : "cci-namespace-13238101",
    "selfLink" : "/apis/metrics.k8s.io/v1beta1/namespaces/cci-namespace-13238101/pods/cci-deployment-20233231-6c8d7f74f7-2t6k5"
  },
  "timestamp" : "2023-03-28T11:28:02Z",
  "window" : "30s"
}
support.huaweicloud.com/api-cci/readMetricsV1beta1NamespacedPodMetrics.html