查询异步操作结果
功能介绍
查询异步操作结果
调试
您可以在API Explorer中调试该接口,支持自动认证鉴权。API Explorer可以自动生成SDK代码示例,并提供SDK代码示例调试功能。
URI
GET /v2/{project_id}/operation/record
| 参数 | 是否必选 | 参数类型 | 描述 | 
|---|---|---|---|
| project_id | 是 | String | 租户从IAM申请到的项目ID,一般为32位字符串 | 
| 参数 | 是否必选 | 参数类型 | 描述 | 
|---|---|---|---|
| blockchain_id | 否 | String | 区块链ID | 
| operation_status | 否 | String | 操作状态, 可选数值如下(括号中为该数值对应的操作状态含义):waiting(等待执行),processing(处理中),finished(操作完成,成功),failed(操作失败),stop(操作中断) 枚举值: 
 | 
| resource_type | 否 | String | 资源类型, 可选数值如下(括号中为该数值对应的资源类型含义):BCSSVC01(BCS变更操作),BCSSVC02(UGBaaS变更操作),PLUGIN01(RestAPI插件变更操作),PLUGIN02(TC3插件变更操作),PLUGIN03(轻节点插件变更操作) 枚举值: 
 | 
| operation_type | 否 | String | 操作类型, 可选数值如下(括号中为该数值对应的操作类型含义):99(OpCreate),00(OpDelete),01(OpUpgrade),91(OpUpgradeRb),02(OpAddOrg),03(OpScaleOrg),04(OpJoinChannel),05(OpJoinUnion) 枚举值: 
 | 
| operation_id | 否 | String | 操作记录ID | 
请求参数
| 参数 | 是否必选 | 参数类型 | 描述 | 
|---|---|---|---|
| X-Auth-Token | 是 | String | 从IAM服务获取的用户Token 最小长度:1 最大长度:32768 | 
响应参数
状态码: 200
| 参数 | 参数类型 | 描述 | 
|---|---|---|
| count | Long | 操作记录总数 | 
| operation_records | Array of RecordDetailInfo objects | 操作记录列表 | 
| 参数 | 参数类型 | 描述 | 
|---|---|---|
| operation_id | String | 操作记录ID | 
| resource_type | String | 资源类型 | 
| operation_type | String | 操作类型 | 
| domain_id | String | 租户ID | 
| project_id | String | 项目ID | 
| blockchain_id | String | 区块链ID | 
| blockchain_name | String | 区块链名称 | 
| cluster_info | OprecordCluster object | 集群信息 | 
| operation_process | Map<String,ProcessInfo> | 操作流程,key为流程名,value为流程信息 | 
| record_time | Long | 记录更新时间 | 
| operation_status | String | 操作状态 | 
| message | Array of strings | 操作过程信息记录 | 
| desc | String | 操作描述 | 
| 参数 | 参数类型 | 描述 | 
|---|---|---|
| cluster_type | String | 集群类型 | 
| name | String | 集群名称 | 
| cluster_id | String | 集群ID | 
| node_infos | Array of NodeInfo objects | 节点信息 | 
| 参数 | 参数类型 | 描述 | 
|---|---|---|
| step_name | String | 操作名 | 
| status | String | 操作状态 | 
| detail | String | 操作详情 | 
| sub_steps | Map<String,SubDetail> | 子操作, "map[string][SubDetail] key:子操作名 value:子操作结果" | 
| serial_num | Long | 序列号 | 
| 参数 | 参数类型 | 描述 | 
|---|---|---|
| substep_name | String | 子操作名 | 
| detail | String | 子操作详情 | 
| status | String | 子操作状态 | 
| message | Array of strings | 子操作过程信息记录 | 
| start_time | Long | 开始时间 | 
| end_time | Long | 结束时间 | 
| serial_num | Long | 序列号 | 
状态码: 400
| 参数 | 参数类型 | 描述 | 
|---|---|---|
| error_code | String | 错误码 最小长度:8 最大长度:36 | 
| error_msg | String | 错误描述 最小长度:2 最大长度:512 | 
状态码: 401
| 参数 | 参数类型 | 描述 | 
|---|---|---|
| error_code | String | 错误码 最小长度:8 最大长度:36 | 
| error_msg | String | 错误描述 最小长度:2 最大长度:512 | 
状态码: 403
| 参数 | 参数类型 | 描述 | 
|---|---|---|
| error_code | String | 错误码 最小长度:8 最大长度:36 | 
| error_msg | String | 错误描述 最小长度:2 最大长度:512 | 
状态码: 404
| 参数 | 参数类型 | 描述 | 
|---|---|---|
| error_code | String | 错误码 最小长度:8 最大长度:36 | 
| error_msg | String | 错误描述 最小长度:2 最大长度:512 | 
状态码: 500
| 参数 | 参数类型 | 描述 | 
|---|---|---|
| error_code | String | 错误码 最小长度:8 最大长度:36 | 
| error_msg | String | 错误描述 最小长度:2 最大长度:512 | 
请求示例
无
响应示例
状态码: 200
Ok
{
  "count" : 1,
  "operation_records" : [ {
    "operation_id" : "BCSSVC01-99-1618218591906093855",
    "resource_type" : "BCSSVC01",
    "operation_type" : "99",
    "domain_id" : "051ddda36880d3420f9bc01403fd8da0",
    "project_id" : "051ddda57400d2982fccc014fab5749d",
    "blockchain_id" : "23604f57-eac9-3777-e9f5-ae87457f2338",
    "blockchain_name" : "bcs-i3b0ms",
    "cluster_info" : {
      "cluster_type" : "cce",
      "name" : "asdfasf",
      "cluster_id" : "4df5652f-96dc-11eb-b49c-0255ac100b08",
      "node_infos" : null
    },
    "operation_process" : {
      "Create Other Dependent Resource" : {
        "step_name" : "Create Other Dependent Resource",
        "status" : "processing",
        "detail" : "",
        "sub_steps" : {
          "Create EIP" : {
            "substep_name" : "Create EIP",
            "detail" : null,
            "status" : "finished",
            "message" : null,
            "start_time" : 1618219038464462600,
            "end_time" : 1618219038464462600,
            "serial_num" : 1
          },
          "Create network storage" : {
            "substep_name" : "Create network storage",
            "detail" : "waiting",
            "status" : "",
            "message" : null,
            "start_time" : 0,
            "end_time" : 0,
            "serial_num" : 2
          }
        },
        "serial_num" : 2
      },
      "Preparation" : {
        "step_name" : "Preparation",
        "status" : "finished",
        "detail" : "",
        "sub_steps" : {
          "Generate basic configurations" : {
            "substep_name" : "Generate basic configurations",
            "detail" : null,
            "status" : "finished",
            "message" : null,
            "start_time" : 1618218591951266000,
            "end_time" : 1618218591951266000,
            "serial_num" : 3
          }
        },
        "serial_num" : 1
      }
    },
    "record_time" : 1618218591906100000,
    "operation_status" : "processing",
    "message" : null,
    "desc" : null
  } ]
}
  状态码: 400
Bad Request
{
  "error_code" : "BCS.4006005",
  "error_msg" : "keyType error, keyType: blok not supported"
}
  状态码: 401
Unauthorized
{
  "error_code" : "BCS.4010401",
  "error_msg" : "Incorrect token or token resolution failed"
}
  状态码: 403
Forbidden
{
  "error_code" : "BCS.4030403",
  "error_msg" : "No permissions to request this method"
}
  状态码: 404
Not Found
{
  "error_code" : "BCS.4040404",
  "error_msg" : "Not Found:the url is not found"
}
  状态码: 500
InternalServerError
{
  "error_code" : "BCS.5000500",
  "error_msg" : "Internal Server Error"
}
 状态码
| 状态码 | 描述 | 
|---|---|
| 200 | Ok | 
| 400 | Bad Request | 
| 401 | Unauthorized | 
| 403 | Forbidden | 
| 404 | Not Found | 
| 500 | InternalServerError | 
错误码
请参见错误码。
 
  