0042-00000202

Updated at:

Problem description

The CompleteMultipartUpload operation does not support specifying a storage class using the x-oss-storage-class request header.

Causes

You sent a CompleteMultipartUpload request that includes the x-oss-storage-class header. This header is not supported for the CompleteMultipartUpload operation.

Problem examples

The following request is an example:

POST /ObjectName?uploadId=UploadId HTTP/1.1
Host: BucketName.oss-cn-hangzhou.aliyuncs.com
Date: GMT Date
Content-Length: Size
Authorization: Signature
x-oss-storage-class: Archive

<CompleteMultipartUpload>
<Part>
<PartNumber>PartNumber</PartNumber>
<ETag>ETag</ETag>
</Part>
...
</CompleteMultipartUpload>

The error is returned because the x-oss-storage-class request header is not supported for the CompleteMultipartUpload operation.

Solutions

Do not include the x-oss-storage-class header in a CompleteMultipartUpload request. If you want to specify a storage class for a file during a multipart upload, you must specify the storage class in the InitiateMultipartUpload request. For example:

POST /multipart.data?uploads HTTP/1.1 
Host: oss-example.oss-cn-hangzhou.aliyuncs.com 
Date: Wed, 22 Feb 2012 08:32:21 GMT 
x-oss-storage-class: Archive
Authorization: OSS qn6q**************:77Dv****************

References