This API is used to query monitoring information about resource pool nodes.
GET /v1/{project_id}/pools/{pool_id}/nodes/{node_ip}/metric-statistic
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
metrics |
No |
String |
Metrics to be queried. Separate metrics by commas (,), for example, CpuUsage,MemUsage. If this parameter is left blank, all metrics are queried. Options:
|
statistic_type |
No |
String |
Metric statistics method, indicating whether to collect metric statistics based on a single GPU. This parameter applies only to GPU metric statistics.
|
Parameter |
Type |
Description |
---|---|---|
error_message |
String |
Error message of a failed API call. This parameter is not included when the API call succeeds. |
error_code |
String |
Indicates the error code when the API fails to be called. Error code of a failed API call. For details, see Error Codes. This parameter is not included when the API call succeeds. |
metrics |
Json Array |
Metric monitoring details. For details, see Table 4. |
interval |
Integer |
Query interval, in minutes. |
The following example queries monitoring information about node 192.168.1.1 in the dedicated resource pool poolabcd.
GET https://endpoint/v1/{project_id}/pools/poolabcd/nodes/192.168.1.1/metric-statistic
{ "metrics": [ { "metric":"gpuUtil", "value":["1","22","33"] } ], "interval" : 1 }
{ "error_message": "Error string", "error_code": "ModelArts.0105" }
For details about the status code, see Status Code.