API for Collecting Dynamic Status v2
Function
Collects dynamic status.
Format
Operation type: GET
URL: https://{ip}:{port}/v2/status
- The {ip} field prioritizes reading the environment variable MIES_CONTAINER_MANAGEMENT_IP. If the environment variable does not exist, managementIpAddress in the configuration file is used. If managementIpAddress does not exist in the configuration file, ipAddress in the configuration file is used.
- The {port} field prioritizes reading the managementPort parameter in the configuration file. If the configuration file does not contain the managementPort parameter, the port parameter in the configuration file is used.
Request Parameters
None
Usage Example
Request example:
GET https://{ip}:{port}/v2/status
{
"service": {
"roleStatus": "RoleUnknown",
"currentRole": "prefill"
},
"resource": {
"totalAvailNpuSlotsNum": 100,
"totalAvailNpuBlockNum": 400,
"maxAvailNpuBlockNum": 100,
},
"linkStatus": {
"peers": [
{
"target": 20000,
"link": "ok"
},
{
"target": 20001,
"link": "ok"
}
]
}
}
Output Description
Field |
Mandatory/Optional |
Type |
Description |
|---|---|---|---|
service |
Mandatory |
Structure |
Service attributes. |
service.roleStatus |
Mandatory |
String |
Role status of the current service. Possible values:
In the prefill-decode hybrid deployment scenario, the value is always RoleReady. |
service.currentRole |
Mandatory |
String |
Role of the current instance. Possible values:
In the prefill-decode hybrid deployment scenario, the value is always none. In the prefill-decode disaggregation scenario, if roleStatus is RoleReady, the value is prefill or decode. If roleStatus is not RoleReady, the value is none. |
resource |
Mandatory |
Structure |
Remaining resources. |
resource.totalAvailNpuSlotsNum |
Mandatory |
Integer |
Number of available slots in all DP groups. |
resource.totalAvailNpuBlockNum |
Mandatory |
Integer |
Number of available blocks in all DP groups. |
resource.maxAvailNpuBlockNum |
Mandatory |
Integer |
Number of available blocks in the DP group with the highest count. |
peers |
Optional |
String array |
The array member is the IP address, indicating the prefill instance that has been successfully connected.
|
linkStatus.peers |
Mandatory |
Structure array |
Connection status of the peer node of the current prefill or decode instance. |
linkStatus.peers[].target |
Mandatory |
Integer |
Instance ID. |
linkStatus.peers[].status |
Mandatory |
String |
Link status of the peer instance. The status of a peer node is set to ok only when the link of all DP groups under the peer node is successfully connected. |