You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by "Jonathan Hsieh (JIRA)" <ji...@apache.org> on 2012/12/15 09:44:12 UTC

[jira] [Commented] (HBASE-7218) Rename Snapshot

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

Jonathan Hsieh commented on HBASE-7218:
---------------------------------------

To make this really safe without funny side effects we'd need need to define semantics in the face of failures properly. 

Some high level possibilities failure handling.

1) Junk on failure.  This is unaccepatble IMO.  If rename crashes we should not leave any corrupted snapshots behind.  I'm concerned about the original ss if (not sure about this) if the recursive hdfs delete is not atomic.
2) Possibility of original and rename present after crash.  This seems less than ideal, but acceptable.
3) Atomic rename -- either it happened or it didn't happen -- with #2 not possible.  Seems ideal.

Are there there other semantics?

To consider: is #2 sufficient?  

Can delete snapshot have the problem -- does it need to do a rename to trash/delete trash approach as well?
How does cloning (reading the snapshot) react if a table is renamed in the middle of the cloning process? 


How necessary is this feature if we can't get to #3's semantics?  Part of me feels like maybe we should punt on this unless we want to make all these cases robust before merge.
                
> Rename Snapshot
> ---------------
>
>                 Key: HBASE-7218
>                 URL: https://issues.apache.org/jira/browse/HBASE-7218
>             Project: HBase
>          Issue Type: Sub-task
>          Components: snapshots
>    Affects Versions: hbase-6055
>            Reporter: Matteo Bertozzi
>            Assignee: Matteo Bertozzi
>            Priority: Minor
>             Fix For: hbase-6055
>
>         Attachments: HBASE-7218-v0.patch, HBASE-7218-v1.patch
>
>
> Add the ability to rename a snapshot.
> HBaseAdmin.renameSnapshot(oldName, newName)
> shell: snapshot_rename 'oldName', 'newName'

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira