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

Zheng Hu edited comment on HBASE-11013 at 5/11/17 2:55 PM:
-----------------------------------------------------------

Add an optional UsersAndPermission field for SnapshotDescription PB.  and I 
encountered two problems:  
1.  UsersAndPermission is a PB in hbase-protocol , and we use  
SnapshotDescription PB in hbase-protocol-shaded,  so, I have to create a copy 
of AccessControl.proto for hbase-protocol-shaded and generate relative Java 
files, which make the patch a little big. 
2.  SnapshotDescription PB was in  HBase.proto and UsersAndPermission was in 
AccessControl.proto before, and AccessControl.proto depended on HBase.proto,  
so I have to move SnapshotDescription PB into Snapshot.proto to avoid recursive 
import. BTW, I think SnapshotDescription should have been in Snapshot.proto. 

In addition, I add an option for restoreSnapshot too, just like cloneSnapshot 
API.   


was (Author: openinx):
Add an optional UsersAndPermission field for SnapshotDescription PB.  and I 
encountered two problems:  
1.  UsersAndPermission is a PB in hbase-protocol , and we use  
SnapshotDescription PB in hbase-protocol-shaded,  so, I have to create a copy 
of AccessControl.proto for hbase-protocol and generate relative java files, 
which make the patch a little big. 
2.  SnapshotDescription PB was in  HBase.proto and UsersAndPermission was in 
AccessControl.proto before, and AccessControl.proto depended on HBase.proto,  
so I have to move SnapshotDescription PB into Snapshot.proto to avoid recursive 
import. 

In addition, I add an option for restoreSnapshot too, just like cloneSnapshot 
API.   

> Clone Snapshots on Secure Cluster Should provide option to apply Retained 
> User Permissions
> ------------------------------------------------------------------------------------------
>
>                 Key: HBASE-11013
>                 URL: https://issues.apache.org/jira/browse/HBASE-11013
>             Project: HBase
>          Issue Type: Improvement
>          Components: snapshots
>            Reporter: Ted Yu
>            Assignee: Zheng Hu
>             Fix For: 2.0.0
>
>         Attachments: HBASE-11013.master.addendum.patch, HBASE-11013.v1.patch, 
> HBASE-11013.v2.patch
>
>
> Currently,
> {code}
> sudo su - test_user
> create 't1', 'f1'
> sudo su - hbase
> snapshot 't1', 'snap_one'
> clone_snapshot 'snap_one', 't2'
> {code}
> In this scenario the user - test_user would not have permissions for the 
> clone table t2.
> We need to add improvement feature such that the permissions of the original 
> table are recorded in snapshot metadata and an option is provided for 
> applying them to the new table as part of the clone process.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to