Devesh Kumar Singh created HDDS-17880:
-----------------------------------------

             Summary: S3G: report the storage class from the stored storage 
policy on GET, HEAD and list
                 Key: HDDS-17880
                 URL: https://issues.apache.org/jira/browse/HDDS-17880
             Project: Apache Ozone
          Issue Type: Sub-task
          Components: Ozone Client, Ozone Manager, S3, s3gateway
            Reporter: Devesh Kumar Singh
            Assignee: Devesh Kumar Singh


S3 responses derive x-amz-storage-class from replication only 
(S3StorageType.fromReplicationConfig in ObjectEndpoint, BucketEndpoint, 
ObjectAttributesHandler, MultipartKeyHandler and ListMultipartUploadsHandler). 
After HDDS-17727, an object written as GLACIER (RATIS + COLD) is stored with 
the COLD policy but still reported as STANDARD.

Report the class with 
S3StorageClassResolver.toS3StorageClass(replicationConfig, storagePolicy) on 
GetObject, HeadObject, ListObjects (v1/v2), GetObjectAttributes, ListParts and 
ListMultipartUploads.

The list and list-parts responses do not carry the policy today, so add an 
optional storagePolicy field:
 - BasicKeyInfo: next free field numberĀ 12.
 - MultipartUploadListPartsResponse: next free field numberĀ 8.

Plumb the field through BasicOmKeyInfo, OmMultipartUploadListParts, 
KeyManagerImpl and the client translator. When the field is absent (keys 
written before the feature, or an old OM), keep today's replication-only answer.



--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to