You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by "Ted Yu (JIRA)" <ji...@apache.org> on 2016/08/09 17:16:20 UTC

[jira] [Commented] (HBASE-16197) Enchance backup delete command

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

Ted Yu commented on HBASE-16197:
--------------------------------

{code}
+    if(tables.contains(tn)) {
{code}
For 'if' and 'for', please insert one space between the keyword and '('.
{code}
+  private int deleteBackup(String backupId, BackupSystemTable table) throws IOException {
{code}
Name the BackupSystemTable parameter sysTable or something similar - there is tn in the for loop, this would make the code easier to read.
{code}
+        // Last backup session for T: YES or NO
+        // ALgorithm:
+        // For every table T from table list 'tables':
{code}
Lift the 'For every' comment to first - T should be defined before referenced.
{code}
+        return Bytes.equals(toByteArray(), other.toByteArray());
+      } catch (IOException e) {
{code}
Is IOE thrown by any methods above ?
{code}
+    // TODO: requires FT, failure will leave system
+    // in non-consistent state
{code}
Would the above be handled in this JIRA ?
{code}
-          LOG.warn("Delete backup failed: no information found for backupID=" + backupId);
+      for (int i = 0; i < backupIds.length; i++) {
{code}
Indentation for 'for' loop should be shifted two spaces to the left.
{code}
     try (final BackupSystemTable table = new BackupSystemTable(conn)) {
{code}
Name table above sysTable.



> Enchance backup delete command
> ------------------------------
>
>                 Key: HBASE-16197
>                 URL: https://issues.apache.org/jira/browse/HBASE-16197
>             Project: HBase
>          Issue Type: Bug
>    Affects Versions: 2.0.0
>            Reporter: Vladimir Rodionov
>            Assignee: Vladimir Rodionov
>             Fix For: 2.0.0
>
>         Attachments: HBASE-16197-v1.patch, HBASE-16197-v2.patch
>
>
> Currently, backup delete command deletes only physical files/directories in backup destination. It does not update backup system table (incremental backup table set) and it does not delete related backup images (previous ones), thus creating a hole in dependency chain. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)