Description
The interface for upgrading OBProxy Server.
Call instructions
Interface constraints
The caller needs to be authenticated through OCP application service.
Request path
POST /api/v2/obproxy/clusters/{id}/obproxies/{obproxyIds}/upgrade
Request parameters
path:
Parameter |
Type |
Required |
Example Value |
Description |
|---|---|---|---|---|
| id | Long | Yes | 33149 | The ID of the OBProxy cluster. |
| obproxyIds | Long | Yes | 1,2 | The ID of the OBProxy server. |
body:
Parameter |
Type |
Required |
Example Value |
Description |
|---|---|---|---|---|
| shortRpmName | String | Yes | obproxy-1.9.1.1-1919579 | The name of the installation package. |
Return result
Basic data structure
Parameter |
Type |
Description |
|---|---|---|
| data | Object | Asynchronous task information. For more information, see Task information. |
| successful | Boolean | Indicates whether the request is successful. |
| timestamp | Datetime | The timestamp when the server finishes processing 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 code specification. |
| traceId | String | The Trace ID of the request, which is used to troubleshoot issues. |
| server | String | The address of the application service that responds to the request. |
Examples
Request example
POST /obproxy/clusters/33149/obproxies/2/upgrade
{
"shortRpmName": "obproxy-1.9.1.1-1919579"
}
Return example
{
"data": {
"creator": "admin",
"executor": "xxx.xxx.xxx.xxx",
"id": 33149,
"name": "Offline obproxy",
"operation": "EXECUTE",
"startTime": "2021-09-03T16:31:58.151+08:00",
"status": "RUNNING",
"subtasks": [{
"description": "Delete obproxy info",
"downstreams": [34970],
"id": 34964,
"name": "Delete obproxy info",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": -1,
"prohibitRollback": false,
"runTime": 1,
"seriesId": 0,
"status": "PENDING",
"timeout": 300,
"upstreams": [34963]
}, {
"description": "Unreserve host",
"downstreams": [34968],
"id": 34966,
"name": "Unreserve host",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": -1,
"prohibitRollback": false,
"runTime": 1,
"seriesId": 3,
"status": "PENDING",
"timeout": 1800,
"upstreams": [34970]
}, {
"description": "Stop and uninstall obproxy",
"downstreams": [34964],
"id": 34963,
"name": "Stop and uninstall obproxy",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": 0,
"prohibitRollback": false,
"runTime": 1,
"seriesId": 1,
"status": "PENDING",
"timeout": 1800,
"upstreams": [34965]
}, {
"description": "Finish node",
"downstreams": [],
"id": 34968,
"name": "Finish node",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": -1,
"prohibitRollback": false,
"runTime": 1,
"seriesId": 2,
"status": "PENDING",
"timeout": 0,
"upstreams": [34966]
}, {
"description": "Offline obproxy exporter",
"downstreams": [34966],
"id": 34970,
"name": "Offline obproxy exporter",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": 0,
"prohibitRollback": false,
"runTime": 1,
"seriesId": 7,
"status": "PENDING",
"timeout": 30,
"upstreams": [34964]
}, {
"description": "Prepare offline obproxy",
"downstreams": [34965],
"id": 34967,
"name": "Prepare offline obproxy",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": 0,
"prohibitRollback": false,
"runTime": 1,
"seriesId": 5,
"status": "PENDING",
"timeout": 1800,
"upstreams": [34969]
}, {
"description": "Wait node",
"downstreams": [34963],
"id": 34965,
"name": "Wait node",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": -1,
"prohibitRollback": false,
"runTime": 1,
"seriesId": 4,
"status": "PENDING",
"timeout": 30,
"upstreams": [34967]
}, {
"description": "Start node",
"downstreams": [34967],
"id": 34969,
"name": "Start node",
"nodeType": "JAVA_TASK",
"operation": "EXECUTE",
"parallelIdx": -1,
"prohibitRollback": false,
"runTime": 1,
"seriesId": 6,
"status": "READY",
"timeout": 30,
"upstreams": []
}],
"taskDefinitionId": -1,
"type": "MANUAL"
},
"duration": 17,
"server": "a83ad33525",
"status": 200,
"successful": true,
"timestamp": "2021-09-03T16:31:58.162+08:00",
"traceId": "0fda4c74b7a84932"
}
