• 沒有找到結果。

5.1 BCS 管理

5.1.17 查询异步操作结果

状态码

状态码 描述

200 Ok

400 Bad Request 401 Unauthorized 403 Forbidden

错误码

请参见错误码。

5.1.17 查询异步操作结果

功能介绍

查询异步操作结果

调试

您可以在API Explorer中调试该接口。

URI

GET /v2/{project_id}/operation/record

5-132 路径参数

参数 是否必选 参数类型 描述

project_id 是 String IAM项目ID

5-133 Query 参数

参数 是否必选 参数类型 描述

blockchain_id 否 String 区块链ID

参数 是否必选 参数类型 描述 operation_stat

us 否 String 操作状态, 可选数值如下(括号

中为该数值对应的操作类型含 义):waiting(等待执行),

processing(处理中),

finished(操作完成,成功),

failed(操作失败),stop(操 作中断)

枚举值:

● waiting

● processing

● finished

● failed

● stop

resource_type 否 String 资源类型, 可选数值如下(括号 中为该数值对应的操作类型含 义):BCSSVC01(BCS变更操 作),BCSSVC02(UGBaaS变 更操作),PLUGIN01(RestAPI 插件变更操作),PLUGIN02

(TC3插件变更操作),

PLUGIN03(轻节点插件变更操 作)

枚举值:

● BCSSVC01

● BCSSVC02

● PLUGIN01

● PLUGIN02

● PLUGIN03

参数 是否必选 参数类型 描述 operation_typ

e 否 String 操作类型, 可选数值如下(括号

中为该数值对应的操作类型含 义):99(OpCreate),00

(OpDelete),01

(OpUpgrade),91

(OpUpgradeRb),02

(OpAddOrg),03

(OpScaleOrg),04

(OpJoinChannel),05

(OpJoinUnion)

枚举值:

● 99

● 00

● 01

● 91

● 02

● 03

● 04

● 05 operation_id 否 String 操作记录ID

请求参数

5-134 请求 Header 参数

参数 是否必选 参数类型 描述

X-Auth-Token 是 String 从IAM服务获取的用户Token 最小长度:1

最大长度:32768

响应参数

状态码: 200

5-135 响应 Body 参数

参数 参数类型 描述

count Long 操作记录总数

参数 参数类型 描述 operation_rec

ords Array of RecordDetailI nfo objects

操作记录列表

5-136 RecordDetailInfo

参数 参数类型 描述

operation_id String 操作记录ID resource_type String 资源类型 operation_typ

e String 操作类型

domain_id String 租户ID project_id String 项目ID blockchain_id String 区块链ID blockchain_na

me String 区块链名称

cluster_info OprecordClus

ter object 集群信息 operation_pro

cess Map<String,P

rocessInfo> 操作流程,key为流程名,value为流程信息 record_time Long 记录更新时间

operation_stat

us String 操作状态

message Array of

strings 操作过程信息记录

desc String 操作描述

5-137 OprecordCluster

参数 参数类型 描述

cluster_type String 集群类型

name String 集群名称

cluster_id String 集群ID

参数 参数类型 描述 node_infos Array of

NodeInfo objects

节点信息

5-138 NodeInfo

参数 参数类型 描述

name String 节点名

id String 节点ID

5-139 ProcessInfo

参数 参数类型 描述

step_name String 操作名 status String 操作状态 detail String 操作详情 sub_steps Map<String,S

ubDetail> 子操作, "map[string][SubDetail] key:子操作名 value:子操作结果"

serial_num Long 序列号

5-140 SubDetail

参数 参数类型 描述

substep_name String 子操作名 detail String 子操作详情 status String 子操作状态 message Array of

strings 子操作过程信息记录 start_time Long 开始时间

end_time Long 结束时间 serial_num Long 序列号

状态码: 400

5-141 响应 Body 参数

参数 参数类型 描述

error_code String 错误码 最小长度:8 最大长度:36 error_msg String 错误描述

最小长度:2 最大长度:512

状态码: 401

5-142 响应 Body 参数

参数 参数类型 描述

error_code String 错误码 最小长度:8 最大长度:36 error_msg String 错误描述

最小长度:2 最大长度:512

状态码: 403

5-143 响应 Body 参数

参数 参数类型 描述

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",

"id" : "4df5652f-96dc-11eb-b49c-0255ac100b08", "node_infos" : null

},

"operation_process" : {

"Create Other Dependent Resource" : {

"step_name" : "Create Other Dependent Resource", "status" : "processing",

"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"

}

状态码

状态码 描述

200 Ok

400 Bad Request 401 Unauthorized 403 Forbidden

错误码

请参见错误码。

相關文件