arrow-left

All pages
gitbookPowered by GitBook
1 of 21

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Loading...

Get trend of restarted pods count in namespace

Get the trend of total number of pods in namespace

Get namespace CPU/Memory total quota

Get namespace creation time

Get namespace pod CPU usage (Core)

Get namespace CPU total usage (Core)

Get namespace Memory total usage (Byte)

Monitoring Namespace

Get namespace creation timechevron-right
Get namespace CPU total usage (Core)chevron-right
Get namespace Memory total usage (Byte)chevron-right
Get namespace CPU/Memory total quotachevron-right
Get namespace pod CPU usage (Core)chevron-right
Get namespace pod Memory usage (Byte)chevron-right
Get the trend of deployment creation count in namespacechevron-right
Get the list of pods in namespacechevron-right
Get the trend of total number of pods in namespacechevron-right
Get the trend of total number of pods by node in namespacechevron-right
Get pods per namespace QoSchevron-right
Get the number of ready pods in the namespacechevron-right
Get the number of ready pods in the namespacechevron-right
Get trend of restarted pods count in namespacechevron-right
Get trend of terminated pods count in namespacechevron-right
Get trend of waiting pods count in namespacechevron-right
Get the total number of PVCs in the namespacechevron-right
Get trend of PVCs by status in the namespacechevron-right
Get namespace PVC usage (Byte)chevron-right
Get current total CPU/Memory usage in the namespacechevron-right
Get the number of pods by status in namespacechevron-right

Get pods per namespace QoS

Get namespace pod Memory usage (Byte)

Get the trend of total number of pods by node in namespace

Get the trend of deployment creation count in namespace

Get the list of pods in namespace

Get namespace PVC usage (Byte)

Get trend of terminated pods count in namespace

Get trend of waiting pods count in namespace

Get trend of PVCs by status in the namespace

Get the total number of PVCs in the namespace

Get the number of ready pods in the namespace

Get the number of pods by status in namespace

Get current total CPU/Memory usage in the namespace

hashtag
Get the trend of total number of pods in namespace

get

Get the trend of the total number of pods deployed in the namespace on a per-minute basis.

Query parameters
clusterIdsstringRequired
namespacesstringOptional
startstringRequired
endstringRequired
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/total-pod-count/result/transition
200

OK

GET /v1/monitoring-ns/metric/total-pod-count/result/transition?clusterIds=text&start=text&end=text HTTP/1.1
Accept: */*
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "namespace": "cocktail-system"
    },
    "samples": [
      55,
      55,
      55
    ],
    "timestamps": [
      1687741080,
      1687741140,
      1687741200
    ],
    "values": null
  }
]

hashtag
Get trend of restarted pods count in namespace

get

Get the trend of the number of pods restarted per minute in the namespace.

Query parameters
clusterIdsstringRequired
namespacesstringOptional
startstringRequired
endstringRequired
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/pod-restart/result/transition
200

OK

GET /v1/monitoring-ns/metric/pod-restart/result/transition?clusterIds=text&start=text&end=text HTTP/1.1
Accept: */*
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "container": "kube-scheduler",
      "namespace": "cocktail-system",
      "pod": "cocktail-api-cmdb-0",
      "workload": "cocktail-api-cmdb"
    },
    "samples": [
      0,
      0,
      0
    ],
    "timestamps": [
      1687741080,
      1687741140,
      1687741200
    ],
    "values": null
  }
]

hashtag
Get namespace pod CPU usage (Core)

get

Get the CPU usage of pods deployed in the namespace.

Query parameters
clusterIdsstringRequired
namespacesstringRequired
startstringRequired
endstringRequired
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/cpu/result/transition
200

OK

GET /v1/monitoring-ns/metric/cpu/result/transition?clusterIds=text&namespaces=text&start=text&end=text HTTP/1.1
Accept: */*
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "measure": "usage-cpu",
      "namespace": "cocktail-system",
      "node": "apps-gpu-v100",
      "pod": "cocktail-api-cmdb-0",
      "workload": "cocktail-api-cmdb"
    },
    "samples": [
      0.00055,
      0.00065,
      0.00067
    ],
    "timestamps": [
      1687741080,
      1687741140,
      1687741200
    ],
    "values": null
  }
]

hashtag
Get namespace CPU/Memory total quota

get

Get the total requested and limited CPU (cores) and memory (bytes) amounts for pods deployed in the namespace.

Query parameters
clusterIdsstringRequired
namespacesstringOptional
startstringRequired
endstringRequired
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/quota/result/transition
200

OK

GET /v1/monitoring-ns/metric/quota/result/transition?clusterIds=text&start=text&end=text HTTP/1.1
Accept: */*
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "measure": "limit-cpu",
      "namespace": "cocktail-system"
    },
    "samples": [
      0,
      0,
      0
    ],
    "timestamps": [
      1687741080,
      1687741140,
      1687741200
    ],
    "values": null
  },
  {
    "metrics": {
      "cluster": "thingcluster",
      "measure": "limit-memory",
      "namespace": "cocktail-system"
    },
    "samples": [
      4760535040,
      4760535040,
      4760535040
    ],
    "timestamps": [
      1687741080,
      1687741140,
      1687741200
    ],
    "values": null
  },
  {
    "metrics": {
      "cluster": "thingcluster",
      "measure": "request-cpu",
      "namespace": "cocktail-system"
    },
    "samples": [
      4.215,
      4.215,
      4.215
    ],
    "timestamps": [
      1687741080,
      1687741140,
      1687741200
    ],
    "values": null
  },
  {
    "metrics": {
      "cluster": "thingcluster",
      "measure": "request-memory",
      "namespace": "cocktail-system"
    },
    "samples": [
      1293547520,
      1293547520,
      1293547520
    ],
    "timestamps": [
      1687741080,
      1687741140,
      1687741200
    ],
    "values": null
  }
]

hashtag
Get namespace creation time

get

Get the creation time of the namespace (timestamp).

Query parameters
clusterIdsstringRequired
namespacesstringOptional
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/created/result/current
200

OK

GET /v1/monitoring-ns/metric/created/result/current?clusterIds=text HTTP/1.1
Accept: */*
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "namespace": "cocktail-system"
    },
    "timestamp": 1687846680,
    "value": 1669945838
  }
]

hashtag
Get namespace Memory total usage (Byte)

get

Get the total memory usage of pods deployed in the namespace.

Query parameters
clusterIdsstringRequired
namespacesstringOptional
startstringRequired
endstringRequired
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/total-memory/result/transition
200

OK

hashtag
Get namespace pod Memory usage (Byte)

get

Get the memory usage of pods deployed in the namespace.

Query parameters
clusterIdsstringRequired
namespacesstringRequired
startstringRequired
endstringRequired
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/memory/result/transition
200

OK

GET /v1/monitoring-ns/metric/total-memory/result/transition?clusterIds=text&start=text&end=text HTTP/1.1
Accept: */*
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "measure": "usage-memory"
    },
    "samples": [
      8434753536,
      8435253248,
      8462614528
    ],
    "timestamps": [
      1687741080,
      1687741140,
      1687741200
    ],
    "values": null
  }
]
GET /v1/monitoring-ns/metric/memory/result/transition?clusterIds=text&namespaces=text&start=text&end=text HTTP/1.1
Accept: */*
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "measure": "usage-memory",
      "namespace": "cocktail-system",
      "node": "apps-gpu-v100",
      "pod": "cocktail-api-cmdb-0",
      "workload": "cocktail-api-cmdb"
    },
    "samples": [
      5505024,
      5480448,
      5570560
    ],
    "timestamps": [
      1687741080,
      1687741140,
      1687741200
    ],
    "values": null
  }
]

hashtag
Get namespace CPU total usage (Core)

get

Get the total CPU usage of pods deployed in the namespace.

Query parameters
clusterIdsstringRequired
namespacesstringOptional
startstringRequired
endstringRequired
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/total-cpu/result/transition
200

OK

GET /v1/monitoring-ns/metric/total-cpu/result/transition?clusterIds=text&start=text&end=text HTTP/1.1
Accept: */*
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "measure": "usage-cpu"
    },
    "samples": [
      1.41992,
      1.32641,
      1.39083
    ],
    "timestamps": [
      1687741080,
      1687741140,
      1687741200
    ],
    "values": null
  }
]

hashtag
Get the trend of total number of pods by node in namespace

get

Get the per-minute trend of the total number of pods deployed on a node in the namespace.

Query parameters
clusterIdsstringRequired
namespacesstringOptional
startstringRequired
endstringRequired
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/pod-count-on-node/result/transition
200

OK

hashtag
Get pods per namespace QoS

get
Query parameters
clusterIdsstringRequired
namespacesstringOptional
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/pod-qos/result/current
200

OK

GET /v1/monitoring-ns/metric/pod-qos/result/current?clusterIds=text HTTP/1.1
Accept: */*
GET /v1/monitoring-ns/metric/pod-count-on-node/result/transition?clusterIds=text&start=text&end=text HTTP/1.1
Accept: */*
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "namespace": "cocktail-system",
      "node": "apps-gpu-v100"
    },
    "samples": [
      5,
      5,
      5
    ],
    "timestamps": [
      1687741080,
      1687741140,
      1687741200
    ],
    "values": null
  }
]
[
  {
    "metrics": {
      "measure": "guarantted"
    },
    "timestamp": 0,
    "value": 0
  },
  {
    "metrics": {
      "measure": "burstable"
    },
    "timestamp": 0,
    "value": 35
  },
  {
    "metrics": {
      "measure": "best-effort"
    },
    "timestamp": 0,
    "value": 20
  }
]

hashtag
Get the trend of deployment creation count in namespace

get

Get the trend of the number of deployments created in the namespace per minute.

Query parameters
clusterIdsstringRequired
namespacesstringOptional
startstringRequired
endstringRequired
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/deployment-created/result/transition
200

OK

GET /v1/monitoring-ns/metric/deployment-created/result/transition?clusterIds=text&start=text&end=text HTTP/1.1
Accept: */*
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "namespace": "cocktail-system"
    },
    "samples": [
      5,
      5,
      5
    ],
    "timestamps": [
      1687741080,
      1687741140,
      1687741200
    ],
    "values": null
  }
]

hashtag
Get trend of terminated pods count in namespace

get

Get the trend of the number of terminated pods per minute in the namespace.

Query parameters
clusterIdsstringRequired
namespacesstringOptional
startstringRequired
endstringRequired
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/pod-terminated/result/transition
200

OK

hashtag
Get the list of pods in namespace

get

Get a list of information, including the creation controller, node, and Pod IP, for the pods deployed in the namespace.

Query parameters
clusterIdsstringRequired
namespacesstringOptional
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/pod-list/result/current
200

OK

hashtag
Get namespace PVC usage (Byte)

get

Get the usage of PVCs created in the namespace.

Query parameters
clusterIdsstringRequired
namespacesstringOptional
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/volume/result/current
GET /v1/monitoring-ns/metric/volume/result/current?clusterIds=text HTTP/1.1
Accept: */*
200

OK

GET /v1/monitoring-ns/metric/pod-list/result/current?clusterIds=text HTTP/1.1
Accept: */*
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "measure": "total",
      "pv_name": "pvc-25d59719-c9d4-48ac-a87a-be5adca980a2",
      "pvc_name": "data-cocktail-monitoring-monitoring-db-0",
      "pvc_namespace": "cocktail-system",
      "storage_class": "nfs-csi",
      "volume_type": "text"
    },
    "timestamp": 1687934760,
    "value": 1099511627776
  }
]
GET /v1/monitoring-ns/metric/pod-terminated/result/transition?clusterIds=text&start=text&end=text HTTP/1.1
Accept: */*
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "namespace": "cocktail-system"
    },
    "samples": [
      0,
      0,
      0
    ],
    "timestamps": [
      1687741080,
      1687741140,
      1687741200
    ],
    "values": null
  }
]
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "creator": "nfd-worker",
      "creator-kind": "DaemonSet",
      "end-point": "http",
      "host_ip": "0.0.0.0",
      "instance": "0.0.0.0:8080",
      "namespace": "cocktail-system",
      "node": "apps-gpu-v100",
      "pod": "cocktail-api-cmdb-0",
      "pod-ip": "0.0.0.0"
    },
    "timestamp": 1687848360,
    "value": 1
  }
]

hashtag
Get the total number of PVCs in the namespace

get

Get the total number of PVCs created in the namespace.

Query parameters
clusterIdsstringRequired
namespacesstringOptional
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/total-pvc-count/result/current
200

OK

hashtag
Get trend of PVCs by status in the namespace

get

Get the per-minute trend of PVC status (Bound, Pending, Lost) created in the namespace.

Query parameters
clusterIdsstringRequired
namespacesstringOptional
startstringRequired
endstringRequired
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/pvc-phase/result/transition
200

OK

hashtag
Get the number of ready pods in the namespace

get

Get the number of pods deployed in the namespace that are in the Ready state.

Query parameters
clusterIdsstringRequired
namespacesstringOptional
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/pod-ready/result/current
200

OK

hashtag
Get the number of pods by status in namespace

post

Get the number of pods in the namespace based on their status (Unknown, Failed, Pending, Running, Succeeded).

Body
Responses
chevron-right
200

OK

*/*
post
/v1/monitoring-ns/metric/pod-status/result/current
200

OK

GET /v1/monitoring-ns/metric/total-pvc-count/result/current?clusterIds=text HTTP/1.1
Accept: */*
GET /v1/monitoring-ns/metric/pod-ready/result/current?clusterIds=text HTTP/1.1
Accept: */*
POST /v1/monitoring-ns/metric/pod-status/result/current HTTP/1.1
Content-Type: application/json
Accept: */*
Content-Length: 80

{
  "clusters": [
    {
      "name": "thingcluster",
      "namespaces": [
        {
          "name": "cocktail-system"
        }
      ]
    }
  ]
}
{
  "thingcluster": {
    "cocktail-system": {
      "pod_run": 39,
      "pod_total": 39,
      "pvc_bound": 0,
      "pvc_lost": 0,
      "pvc_pending": 0
    }
  }
}
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "namespace": "cocktail-system"
    },
    "timestamp": 1687932960,
    "value": 23
  }
]
GET /v1/monitoring-ns/metric/pvc-phase/result/transition?clusterIds=text&start=text&end=text HTTP/1.1
Accept: */*
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "namespace": "cocktail-system",
      "phase": "Pending",
      "pvc": "data-cocktail-monitoring-monitoring-db-0"
    },
    "samples": [
      0,
      0,
      0
    ],
    "timestamps": [
      1687741080,
      1687741140,
      1687741200
    ],
    "values": null
  }
]
[
  {
    "metrics": {
      "ready": "78"
    },
    "timestamp": 1687851000,
    "value": 78
  }
]

hashtag
Get current total CPU/Memory usage in the namespace

post

Get the current total requested, limit, and usage of CPU (Core) and Memory (Byte) for the pods deployed in the namespace.

Body
Responses
chevron-right
200

OK

*/*
post
/v1/monitoring-ns/metric/total-resource/result/current
200

OK

hashtag
Get trend of waiting pods count in namespace

get

Get the trend of the number of pods in the waiting state per minute in the namespace.

Query parameters
clusterIdsstringRequired
namespacesstringOptional
startstringRequired
endstringRequired
Responses
chevron-right
200

OK

*/*
get
/v1/monitoring-ns/metric/pod-waiting/result/transition
200

OK

POST /v1/monitoring-ns/metric/total-resource/result/current HTTP/1.1
Content-Type: application/json
Accept: */*
Content-Length: 38

{
  "clusters": [
    {
      "name": "thingcluster"
    }
  ]
}
{
  "thingcluster": {
    "cocktail-system": {
      "limit_cpu": 0,
      "limit_memory": 4760535040,
      "request_cpu": 4215,
      "request_memory": 1293547520,
      "usage_cpu": 1298,
      "usage_memory": 8463978496
    },
    "limit_cpu": 57900,
    "limit_memory": 87966199808,
    "request_cpu": 26665,
    "request_memory": 37130840064,
    "usage_cpu": 2439,
    "usage_memory": 51958136832
  }
}
GET /v1/monitoring-ns/metric/pod-waiting/result/transition?clusterIds=text&start=text&end=text HTTP/1.1
Accept: */*
[
  {
    "metrics": {
      "cluster": "thingcluster",
      "namespace": "cocktail-system"
    },
    "samples": [
      0,
      0,
      0
    ],
    "timestamps": [
      1687741080,
      1687741140,
      1687741200
    ],
    "values": null
  }
]