Problem description
The OptionalFields node in the PutBucketInventory request contains an invalid item.
Causes
The OptionalFields node in the PutBucketInventory request contains an invalid item. The item is not supported by the PutBucketInventory operation.
Examples
In the following request, the OptionalFields node contains an invalid <Field>StartTime</Field> item. In this case, an error is reported.
PUT /?inventory&inventoryId=report1 HTTP/1.1
Host: BucketName.oss.aliyuncs.com
Date: Mon, 31 Oct 2016 12:00:00 GMT
Authorization: authorization string
Content-Length: length
<?xml version="1.0" encoding="UTF-8"?>
<InventoryConfiguration>
<Id>report1</Id>
<IsEnabled>true</IsEnabled>
<Filter>
<Prefix>filterPrefix/</Prefix>
<LastModifyBeginTimeStamp>1637883649</LastModifyBeginTimeStamp>
<LastModifyEndTimeStamp>1638347592</LastModifyEndTimeStamp>
<LowerSizeBound>1024</LowerSizeBound>
<UpperSizeBound>2048</UpperSizeBound>
<StorageClass>Standard,IA</StorageClass>
</Filter>
<Destination>
<OSSBucketDestination>
<Format>CSV</Format>
<AccountId>1000000000000000</AccountId>
<RoleArn>acs:ram::1000000000000000:role/AliyunOSSRole</RoleArn>
<Bucket>acs:oss:::destination-bucket</Bucket>
<Prefix>prefix1</Prefix>
</OSSBucketDestination>
</Destination>
<Schedule>
<Frequency>Daily</Frequency>
</Schedule>
<IncludedObjectVersions>All</IncludedObjectVersions>
<OptionalFields>
<Field>Size</Field>
<Field>LastModifiedDate</Field>
<Field>ETag</Field>
<Field>StorageClass</Field>
<Field>IsMultipartUploaded</Field>
<Field>StartTime</Field>
</OptionalFields>
</InventoryConfiguration>Solutions
Delete the <Field>StartTime</Field> item under the OptionalFields node in the PutBucketInventory request.
Specify the items that are included in the inventory list by specifying the Field parameters under the OptionalFields node. The following items are included in the inventory list:
Key: The name of the object in the bucket. The name is URL-encoded.
VersionId: The version ID of the object. This field is included only if IncludedObjectVersions is set to All.
If versioning is not enabled for the bucket, this field is empty.
If versioning is enabled for the bucket, this field contains the version ID of the object.
IsDeleteMarker: Specifies whether the object version is a delete marker. This field is included only if IncludedObjectVersions is set to All.
If versioning is not enabled for the bucket, this field is set to false by default.
If versioning is enabled and the object is a delete marker, this field is set to true. If the object is not a delete marker, this field is set to false.
Size: The size of the object.
StorageClass: The storage class of the object.
TransitionTime: The time when the object was transitioned to the Archive or Cold Archive storage class by a lifecycle rule.
LastModifiedDate: The last modified time of the object.
ETag: The ETag of the object. The ETag is generated when an object is created and identifies the content of the object.
For an object created by using the PutObject operation, its ETag is the MD5 hash of the object content.
For an object created by using other methods, its ETag is a unique value calculated based on a specific rule and is not the MD5 hash of the object content.
IsMultipartUploaded: Specifies whether the object was uploaded by using a multipart upload.
ObjectType: The type of the object.
ObjectAcl: The access control list (ACL) of the object.
Crc64: The CRC-64 value of the object.
EncryptionStatus: Specifies whether the object is encrypted.
TaggingCount: The number of tags.