Description
This topic describes the API for stopping an OBProxy server.
Considerations
Authentication
The request must be authenticated by using OCP.
Request path
POST /api/v2/obproxy/clusters/{id}/servers/stop
Request parameters
Path parameters:
Parameter |
Type |
Required |
Example value |
Description |
|---|---|---|---|---|
| id | Long | Yes | 1 | The ID of the OBProxy cluster. |
Body parameters:
Parameter |
Type |
Required |
Example value |
Description |
|---|---|---|---|---|
| obproxyServerIds | Long | Yes | [1,2,3] | The ID of the OBProxy server to be stopped. |
Return result
Basic data structure
Parameter |
Type |
Description |
|---|---|---|
| data | Object | The asynchronous task information. For more information, see Task information. |
| successful | Boolean | Specifies whether the request is successful. |
| timestamp | Datetime | The timestamp when the server finishes the request. |
| duration | Integer | The time taken by the server to process the request, in milliseconds. |
| status | Integer | The HTTP status code that conforms to the HTTP Status specification. |
| traceId | String | The Trace ID of the request, which is used for troubleshooting. |
| server | String | The address of the application service that responds to the request. |
Examples
Request example
POST /api/v2/obproxy/clusters/1/servers/stop
{
"obproxyServerIds": [
1,
2,
3
]
}
Return example
{
"data": {
"creator": "admin",
"executor": "xxx.xxx.xxx.xxx",
"id": 13153183,
"name": "Stop obproxy",
"operation": "EXECUTE",
"prohibitRollback": false,
"startTime": "2025-01-16T11:43:38.273+08:00",
"status": "RUNNING",
"subtasks": [
{
"description": "Stop obproxy",
"downstreams": [
13175726
],
"id": 13175719,
"name": "Stop obproxy",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": 0,
"prohibitRollback": true,
"prohibitSkip": false,
"runTime": 1,
"seriesId": 10,
"status": "PENDING",
"taskId": 13153183,
"timeout": 1800,
"upstreams": [
13175727
]
},
{
"description": "Start node",
"downstreams": [
13175728
],
"id": 13175720,
"name": "Start node",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": -1,
"prohibitRollback": false,
"prohibitSkip": false,
"runTime": 1,
"seriesId": 0,
"status": "READY",
"taskId": 13153183,
"timeout": 30,
"upstreams": []
},
{
"description": "Wait node",
"downstreams": [
13175724
],
"id": 13175725,
"name": "Wait node",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": -1,
"prohibitRollback": false,
"prohibitSkip": false,
"runTime": 1,
"seriesId": 3,
"status": "PENDING",
"taskId": 13153183,
"timeout": 30,
"upstreams": [
13175722
]
},
{
"description": "Prepare stop obproxy",
"downstreams": [
13175723
],
"id": 13175728,
"name": "Prepare stop obproxy",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": 0,
"prohibitRollback": false,
"prohibitSkip": false,
"runTime": 1,
"seriesId": 5,
"status": "PENDING",
"taskId": 13153183,
"timeout": 1800,
"upstreams": [
13175720
]
},
{
"description": "Update obproxy status",
"downstreams": [
13175725
],
"id": 13175722,
"name": "Update obproxy status",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": 0,
"prohibitRollback": false,
"prohibitSkip": false,
"runTime": 1,
"seriesId": 6,
"status": "PENDING",
"taskId": 13153183,
"timeout": 300,
"upstreams": [
13175729
]
},
{
"description": "Wait node",
"downstreams": [
13175727
],
"id": 13175723,
"name": "Wait node",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": -1,
"prohibitRollback": false,
"prohibitSkip": false,
"runTime": 1,
"seriesId": 1,
"status": "PENDING",
"taskId": 13153183,
"timeout": 30,
"upstreams": [
13175728
]
},
{
"description": "Inactive agent modules",
"downstreams": [
13175729
],
"id": 13175721,
"name": "Inactive agent modules",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": 0,
"prohibitRollback": false,
"prohibitSkip": false,
"runTime": 1,
"seriesId": 9,
"status": "PENDING",
"taskId": 13153183,
"timeout": 3600,
"upstreams": [
13175726
]
},
{
"description": "Wait node",
"downstreams": [
13175721
],
"id": 13175726,
"name": "Wait node",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": -1,
"prohibitRollback": false,
"prohibitSkip": false,
"runTime": 1,
"seriesId": 4,
"status": "PENDING",
"taskId": 13153183,
"timeout": 30,
"upstreams": [
13175719
]
},
{
"description": "Update obproxy cluster lock status",
"downstreams": [],
"id": 13175724,
"name": "Update obproxy cluster lock status",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": -1,
"prohibitRollback": false,
"prohibitSkip": false,
"runTime": 1,
"seriesId": 8,
"status": "PENDING",
"taskId": 13153183,
"timeout": 60,
"upstreams": [
13175725
]
},
{
"description": "Prevent obproxy from accepting new request",
"downstreams": [
13175719
],
"id": 13175727,
"name": "Prevent obproxy from accepting new request",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": -1,
"prohibitRollback": false,
"prohibitSkip": false,
"runTime": 1,
"seriesId": 2,
"status": "PENDING",
"taskId": 13153183,
"timeout": 300,
"upstreams": [
13175723
]
},
{
"description": "Wait node",
"downstreams": [
13175722
],
"id": 13175729,
"name": "Wait node",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": -1,
"prohibitRollback": false,
"prohibitSkip": false,
"runTime": 1,
"seriesId": 7,
"status": "PENDING",
"taskId": 13153183,
"timeout": 30,
"upstreams": [
13175721
]
}
],
"taskDefinitionId": -1,
"type": "MANUAL"
},
"duration": 59,
"server": "74f95ea2f4",
"status": 200,
"successful": true,
"timestamp": "2025-01-16T11:43:38.311+08:00",
"traceId": "b16d0fa52e048f63"
}
