GetBucketReplication
更新时间:2020-11-25
接口描述
本接口用来获取bucket指定id的数据同步信息,包括源Bucket名称、目的Bucket名称、存储类型、是否进行历史复制,数据同步策略,目的region等。
请求(Request)
-
请求语法
GET /?replication&id=sample-bucket HTTP/1.1 Host: <BucketName>.bj.bcebos.com Date: <GMT Date> Authorization: AuthorizationString
-
请求头域
无特殊参数
-
请求参数
无特殊参数
响应(Response)
-
响应元素
参数 描述 id replication规则名 status 是否生效 resource replication生效前缀 destination 复制的目的端配置 +bucket 目的Bucket name +storageClass 目的Object的存储类型。如果保持和源Bucket的存储类型一致,则该参数为空; STANDARD
表示标准存储类型,STANDARD_IA
表示低频存储类型,COLD
表示冷存储类型;如果是多AZ类型bucket,可取值为MAZ_STANDARD_IA
和MAZ_STANDARD
。replicateHistory 历史文件复制,有该项则认为是开启 +storageClass 目的Object的存储类型,默认为 REMAIN
,可以为STANDARD
,STANDARD_IA
,COLD
,MAZ_STANDARD_IA
,MAZ_STANDARD
replicateDeletes 是否开启删除同步,可以为 enabled
,disabled
create_time replication规则创建时间 destRegion 目的region -
响应头域
无特殊参数
示例
-
请求示例
GET /?replication&id=sample-bucket HTTP/1.1 Host: BucketName.bj.bcebos.com Date: Thu, 15 May 2017 00:17:23 GMT Authorization: AuthorizationString
-
响应示例
HTTP/1.1 200 OK Date: Thu, 15 May 2017 00:17:23 GMT Server: BceBos x-bce-request-id: xxxx-xxxxx-xxxx Connection: keep-alive Content-Length: xxx { "status": "enabled", "resource": [ "src-bucket-name/abc", "src-bucket-name/cd*" ], "destination": { "bucket": "dst-bucket-name", "storageClass": "COLD" }, "replicateHistory": { "storageClass": "COLD" }, "replicateDeletes": "enabled", "id": "sample-bucket", "create_time": 1583060606, "destRegion":"bj" }