[ 
https://issues.apache.org/jira/browse/HDDS-793?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16748640#comment-16748640
 ] 

Elek, Marton commented on HDDS-793:
-----------------------------------

Thanks the review [~xyao]

I rebased the patch on top of the latest trunk and improved it.
{quote}Since Volume/Bucket/Key all have these metadata map, can we add a common 
base class that support get/set metadata to de-dup the changes?
{quote}
I also considered it, but it's not always possible. For example KeyInfoDetails 
already has a parent class, I can't add  more. In the latest patch I introduced 
a new parent class ("WithMetadata") I tried to use everywhere it's possible.
{quote}BucketManagerImpl.java

Line 168: should we add the MetadataMap into the bucketInfoBuilder in 
setBucketProperty() as well?
{quote}
Sure, I added the support of modify the bucket metadata. Also added the missing 
metadata to the proto file.
{quote}bq. DistributedStorageHandler.java
{quote}
For the sake of the simplicity I removed all the rest related improvements. 
Recently we discussed offline that HDDS-738 can be implemented soon which will 
remove the rest related classes. Until that the metadata won't be supported in 
the rest interface.
{quote}OzoneKey.java

Should we expose the metadata here as well?
{quote}
OzoneKey is for the listKey call, OzoneKeyDetails for the getKey call. As 
metadata requires additional size I prefer to put it only to the response of 
getKey to keep the response of the listKey as small as possible. (Unless we 
have an explicit use case to add some metadata to the list).

 

 

> Support custom key/value annotations on volume/bucket/key
> ---------------------------------------------------------
>
>                 Key: HDDS-793
>                 URL: https://issues.apache.org/jira/browse/HDDS-793
>             Project: Hadoop Distributed Data Store
>          Issue Type: New Feature
>          Components: OM
>            Reporter: Elek, Marton
>            Assignee: Elek, Marton
>            Priority: Major
>              Labels: pull-request-available
>         Attachments: HDDS-793.001.patch, HDDS-793.002.patch, 
> HDDS-793.003.patch
>
>          Time Spent: 10m
>  Remaining Estimate: 0h
>
> I propose to add a custom Map<String,String> annotation field to 
> objects/buckets and keys in Ozone Manager.
> It would enable to build any extended functionality on top of the OM's 
> generic interface. For example:
>  * Support tags in Ozone S3 gateway 
> (https://docs.aws.amazon.com/AmazonS3/latest/API/RESTObjectGETtagging.html)
>  * Support md5 based ETags in s3g
>  * Store s3 related authorization data (ACLs, policies) together with the 
> parent objects
> As an optional feature (could be implemented later) the client can defined 
> the exposed annotations. For example s3g can defined which annotations should 
> be read from rocksdb on OM side and sent the the client (s3g)



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

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

Reply via email to