首批通过分布式安全可靠测评,为关键业务系统打造
修改租户 Zone 优先级
更新时间:2023-08-10 11:45:58
功能说明
修改指定租户的 Zone 优先级时使用的接口。
调用说明
接口约束
调用者需要通过 OCP 应用服务鉴权。
请求路径
POST /api/v2/ob/clusters/{id}/tenants/{tenantId}/modifyPrimaryZone
path:
| 参数 | 类型 | 必选 | 示例值 | 描述 |
|---|---|---|---|---|
| id | Long | 是 | 1 | 集群 ID |
| tenantId | Long | 是 | 1 | 租户 ID |
请求参数
| 参数 | 类型 | 必选 | 示例值 | 描述 |
|---|---|---|---|---|
| primaryZone | String | 是 | zone1;zone2,zone3 | Zone 优先级 |
返回结果
基础数据结构
| 参数 | 类型 | 说明 |
|---|---|---|
| successful | Boolean | 请求是否成功。 |
| timestamp | Datetime | 服务端完成请求的时间戳。 |
| duration | Integer | 服务端处理请求的时间(毫秒)。 |
| status | Integer | 符合 HTTP Status 规范的编码。 |
| traceId | String | 请求的 Trace ID,用于排查问题。 |
| server | String | 响应请求的应用服务的地址。 |
示例
请求示例
POST /api/v2/ob/clusters/1/tenants/2/modifyPrimaryZone
body:
{
"primaryZone": "zone1;zone2,zone3"
}
返回示例
{
"duration": 233,
"server": "a83ad33525",
"status": 200,
"successful": true,
"timestamp": "2021-03-02T16:02:24.643+08:00",
"traceId": "49556176bcfe439b"