[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-11-26 Thread Hudson (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13832508#comment-13832508
 ] 

Hudson commented on HBASE-8465:
---

SUCCESS: Integrated in HBase-TRUNK-on-Hadoop-2.0.0 #852 (See 
[https://builds.apache.org/job/HBase-TRUNK-on-Hadoop-2.0.0/852/])
HBASE-8465 Auto-drop rollback snapshot for snapshot restore (mbertozzi: rev 
1545360)
* 
/hbase/trunk/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseAdmin.java
* /hbase/trunk/hbase-common/src/main/resources/hbase-default.xml
* 
/hbase/trunk/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestRestoreSnapshotFromClient.java


 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Matteo Bertozzi
 Fix For: 0.98.0, 0.96.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt, 
 HBASE-8465-v3.patch, HBASE-8465-v4.patch, HBASE-8465-v5.patch, 
 HBASE-8465-v6.patch


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.



--
This message was sent by Atlassian JIRA
(v6.1#6144)


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-11-25 Thread Hudson (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13831873#comment-13831873
 ] 

Hudson commented on HBASE-8465:
---

SUCCESS: Integrated in hbase-0.96 #204 (See 
[https://builds.apache.org/job/hbase-0.96/204/])
HBASE-8465 Auto-drop rollback snapshot for snapshot restore (mbertozzi: rev 
1545361)
* 
/hbase/branches/0.96/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseAdmin.java
* /hbase/branches/0.96/hbase-common/src/main/resources/hbase-default.xml
* 
/hbase/branches/0.96/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestRestoreSnapshotFromClient.java


 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Matteo Bertozzi
 Fix For: 0.98.0, 0.96.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt, 
 HBASE-8465-v3.patch, HBASE-8465-v4.patch, HBASE-8465-v5.patch, 
 HBASE-8465-v6.patch


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.



--
This message was sent by Atlassian JIRA
(v6.1#6144)


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-11-25 Thread Hudson (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13832184#comment-13832184
 ] 

Hudson commented on HBASE-8465:
---

SUCCESS: Integrated in hbase-0.96-hadoop2 #132 (See 
[https://builds.apache.org/job/hbase-0.96-hadoop2/132/])
HBASE-8465 Auto-drop rollback snapshot for snapshot restore (mbertozzi: rev 
1545361)
* 
/hbase/branches/0.96/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseAdmin.java
* /hbase/branches/0.96/hbase-common/src/main/resources/hbase-default.xml
* 
/hbase/branches/0.96/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestRestoreSnapshotFromClient.java


 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Matteo Bertozzi
 Fix For: 0.98.0, 0.96.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt, 
 HBASE-8465-v3.patch, HBASE-8465-v4.patch, HBASE-8465-v5.patch, 
 HBASE-8465-v6.patch


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.



--
This message was sent by Atlassian JIRA
(v6.1#6144)


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-11-25 Thread Hudson (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13832254#comment-13832254
 ] 

Hudson commented on HBASE-8465:
---

FAILURE: Integrated in HBase-TRUNK #4698 (See 
[https://builds.apache.org/job/HBase-TRUNK/4698/])
HBASE-8465 Auto-drop rollback snapshot for snapshot restore (mbertozzi: rev 
1545360)
* 
/hbase/trunk/hbase-client/src/main/java/org/apache/hadoop/hbase/client/HBaseAdmin.java
* /hbase/trunk/hbase-common/src/main/resources/hbase-default.xml
* 
/hbase/trunk/hbase-server/src/test/java/org/apache/hadoop/hbase/client/TestRestoreSnapshotFromClient.java


 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Matteo Bertozzi
 Fix For: 0.98.0, 0.96.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt, 
 HBASE-8465-v3.patch, HBASE-8465-v4.patch, HBASE-8465-v5.patch, 
 HBASE-8465-v6.patch


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.



--
This message was sent by Atlassian JIRA
(v6.1#6144)


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-11-19 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13826968#comment-13826968
 ] 

Ted Yu commented on HBASE-8465:
---

Patch v6 is good to go.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Matteo Bertozzi
 Fix For: 0.98.0, 0.96.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt, 
 HBASE-8465-v3.patch, HBASE-8465-v4.patch, HBASE-8465-v5.patch, 
 HBASE-8465-v6.patch


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.



--
This message was sent by Atlassian JIRA
(v6.1#6144)


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-11-18 Thread Hadoop QA (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13826131#comment-13826131
 ] 

Hadoop QA commented on HBASE-8465:
--

{color:red}-1 overall{color}.  Here are the results of testing the latest 
attachment 
  http://issues.apache.org/jira/secure/attachment/12614520/HBASE-8465-v6.patch
  against trunk revision .

{color:green}+1 @author{color}.  The patch does not contain any @author 
tags.

{color:green}+1 tests included{color}.  The patch appears to include 3 new 
or modified tests.

{color:green}+1 hadoop1.0{color}.  The patch compiles against the hadoop 
1.0 profile.

{color:green}+1 hadoop2.0{color}.  The patch compiles against the hadoop 
2.0 profile.

{color:red}-1 javadoc{color}.  The javadoc tool appears to have generated 
10 warning messages.

{color:green}+1 javac{color}.  The applied patch does not increase the 
total number of javac compiler warnings.

{color:green}+1 findbugs{color}.  The patch does not introduce any new 
Findbugs (version 1.3.9) warnings.

{color:green}+1 release audit{color}.  The applied patch does not increase 
the total number of release audit warnings.

{color:green}+1 lineLengths{color}.  The patch does not introduce lines 
longer than 100

{color:red}-1 site{color}.  The patch appears to cause mvn site goal to 
fail.

{color:green}+1 core tests{color}.  The patch passed unit tests in .

Test results: 
https://builds.apache.org/job/PreCommit-HBASE-Build/7924//testReport/
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/7924//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-protocol.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/7924//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-thrift.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/7924//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-client.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/7924//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-examples.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/7924//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-hadoop1-compat.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/7924//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-prefix-tree.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/7924//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-common.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/7924//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-server.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/7924//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-hadoop-compat.html
Console output: 
https://builds.apache.org/job/PreCommit-HBASE-Build/7924//console

This message is automatically generated.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Matteo Bertozzi
 Fix For: 0.98.0, 0.96.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt, 
 HBASE-8465-v3.patch, HBASE-8465-v4.patch, HBASE-8465-v5.patch, 
 HBASE-8465-v6.patch


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.



--
This message was sent by Atlassian JIRA
(v6.1#6144)


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-11-15 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13824296#comment-13824296
 ] 

Ted Yu commented on HBASE-8465:
---

lgtm

Please check findbugs.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Matteo Bertozzi
 Fix For: 0.98.0, 0.96.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt, 
 HBASE-8465-v3.patch, HBASE-8465-v4.patch, HBASE-8465-v5.patch


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.



--
This message was sent by Atlassian JIRA
(v6.1#6144)


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-11-14 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13822777#comment-13822777
 ] 

Ted Yu commented on HBASE-8465:
---

{code}
+hbase-failsafe-{snapshot.name}-{restore.timestamp});
+  failSafeSnapshotSnapshotName = failSafeSnapshotSnapshotName
+.replace({snapshot.name}, snapshotName)
+.replace({table.name}, 
tableName.toString().replace(TableName.NAMESPACE_DELIM, '.'))
{code}
{table.name} doesn't appear in the default template. Please add comment in 
hbase-default.xml

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Matteo Bertozzi
 Fix For: 0.98.0, 0.96.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt, 
 HBASE-8465-v3.patch, HBASE-8465-v4.patch


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.



--
This message was sent by Atlassian JIRA
(v6.1#6144)


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-11-14 Thread Hadoop QA (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13823329#comment-13823329
 ] 

Hadoop QA commented on HBASE-8465:
--

{color:red}-1 overall{color}.  Here are the results of testing the latest 
attachment 
  http://issues.apache.org/jira/secure/attachment/12613999/HBASE-8465-v5.patch
  against trunk revision .

{color:green}+1 @author{color}.  The patch does not contain any @author 
tags.

{color:green}+1 tests included{color}.  The patch appears to include 6 new 
or modified tests.

{color:green}+1 hadoop1.0{color}.  The patch compiles against the hadoop 
1.0 profile.

{color:green}+1 hadoop2.0{color}.  The patch compiles against the hadoop 
2.0 profile.

{color:red}-1 javadoc{color}.  The javadoc tool appears to have generated 1 
warning messages.

{color:green}+1 javac{color}.  The applied patch does not increase the 
total number of javac compiler warnings.

{color:red}-1 findbugs{color}.  The patch appears to cause Findbugs 
(version 1.3.9) to fail.

{color:green}+1 release audit{color}.  The applied patch does not increase 
the total number of release audit warnings.

{color:green}+1 lineLengths{color}.  The patch does not introduce lines 
longer than 100

{color:red}-1 site{color}.  The patch appears to cause mvn site goal to 
fail.

{color:green}+1 core tests{color}.  The patch passed unit tests in .

Test results: 
https://builds.apache.org/job/PreCommit-HBASE-Build/7874//testReport/
Console output: 
https://builds.apache.org/job/PreCommit-HBASE-Build/7874//console

This message is automatically generated.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Matteo Bertozzi
 Fix For: 0.98.0, 0.96.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt, 
 HBASE-8465-v3.patch, HBASE-8465-v4.patch, HBASE-8465-v5.patch


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.



--
This message was sent by Atlassian JIRA
(v6.1#6144)


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-11-13 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13822016#comment-13822016
 ] 

Ted Yu commented on HBASE-8465:
---

{code}
+  failSafeSnapshotSnapshotName = 
conf.get(hbase.snapshot.restore.failsafe.name,
+hbase-restore-failsafe-{table.name}-{restore.timestamp});
{code}
The failsafe snapshot name is pretty long. Can it include the snapshotName for 
the restore operation ?
{code}
+  String msg = Restore snapshot= + snapshotName +
+ failed. Rollback to snapshot= + failSafeSnapshotSnapshotName + 
 succeeded.;
+  LOG.error(msg, e);
+  internalRestoreSnapshot(failSafeSnapshotSnapshotName, tableName);
{code}
The success message seems to come a bit early.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Fix For: 0.98.0, 0.96.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt, HBASE-8465-v3.patch


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.



--
This message was sent by Atlassian JIRA
(v6.1#6144)


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-11-07 Thread Enis Soztutar (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13816930#comment-13816930
 ] 

Enis Soztutar commented on HBASE-8465:
--

I was reading the restore code for something else, and was very surprised by 
automatic taking of the snapshots. We also do not delete that snapshot even 
after the restore is successful. 

+1 on introducing an API where taking a snapshot before restore is configurable 
(through arg passing, not conf). Also in case the snapshot restore is success, 
we should delete the previous snapshot. The arg name for this 
(dropRollbackSnapshot) might be confusing since the user might think that it 
will drop the original snapshot, not the one for restore. 


 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Fix For: 0.98.0, 0.96.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.



--
This message was sent by Atlassian JIRA
(v6.1#6144)


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-05-02 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13647672#comment-13647672
 ] 

Ted Yu commented on HBASE-8465:
---

bq. and if we have the ability to specify the name of the failsafe snapshot, 
the admin can delete the failsafe before enabling the restored table.
I think it is intuitive to auto-drop the failsafe snapshot after successful 
restore. Making this action configurable means adding another option 
(dropFailsafeSnapshot) for the restore command.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Fix For: 0.98.0, 0.95.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-05-02 Thread Jonathan Hsieh (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13647997#comment-13647997
 ] 

Jonathan Hsieh commented on HBASE-8465:
---

If we only have opinions let's look to how other systems do this as a tie 
breaker.  What happens when you take do an overwriting snapshot restore of 
postgres, mysql or oracle databases.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Fix For: 0.98.0, 0.95.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-05-02 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13648072#comment-13648072
 ] 

Ted Yu commented on HBASE-8465:
---

Looking through 
http://dev.mysql.com/doc/refman/5.1/en/point-in-time-recovery.html , I don't 
see mentioning of failsafe snapshot (or its equivalent).

Will see how Oracle handles snapshot restore.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Fix For: 0.98.0, 0.95.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-05-01 Thread Jonathan Hsieh (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13647024#comment-13647024
 ] 

Jonathan Hsieh commented on HBASE-8465:
---

bq. The name of rollback snapshot is not returned. Person issuing restore 
command may not be aware of the existence of rollback snapshot. Later, when 
list_snapshots command reveals the rollback snapshots, people are surprised. I 
think dropping the rollback snapshot is desirable.

I think we should have the user specify the snapshot taken on restore.  (and 
deprecate the autonaming if that is confusing).

In v2 I don't see the change from dropRollback wording to snapshotOnRestore 
wording in the code.  With this option we dropRollback but matteo's suggestion 
was to not even take the rollback snapshot in the firstplace.

Following through would mean converting this 
 
{code}
+  private static final String 
RESTORE_DROP_ROLLBACK_SNAPSHOT=hbase.snapshot.restore.drop.rollback;
{code}

to something like {{... TAKE_SNAPSHOT_ON_RESTORE = 
hbase.snapshot.restore.takesnapshot}}

An example would be (default would be after the change would be true instead of 
false):

{code}
- public void restoreSnapshot(final byte[] snapshotName, final boolean 
dropRollbackSnapshot
+ public void restoreSnapshot(final byte[] snapshotName, final boolean 
takeSnapshot)
{code}

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Fix For: 0.98.0, 0.95.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-05-01 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13647028#comment-13647028
 ] 

Ted Yu commented on HBASE-8465:
---

Suppose we introduce takeSnapshot for the rollback snapshot, do we still need 
the dropRollbackSnapshot option (when takeSnapshot is true) ?

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Fix For: 0.98.0, 0.95.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-05-01 Thread Matteo Bertozzi (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13647035#comment-13647035
 ] 

Matteo Bertozzi commented on HBASE-8465:


{quote}With this option we dropRollback but matteo's suggestion was to not even 
take the rollback snapshot in the firstplace.{quote}
I tought you were against this one... and I guess Ted read it in my same way

{quote}public void restoreSnapshot(final byte[] snapshotName, final boolean 
takeSnapshot){quote}
wait... instead of doing this at this point we should use String 
failsafeSnapshotName and have the default one in the default method...

{code}
restore(tableName) {
   if (conf.restore.failsafe.snapshot == true)
  restore(tableName, snapshot-for-rollback-name);
   else
  restore(tableName, null);
}

restore(tableName, failsafeSnapshotName) {
   if (failsafeSnapshotName != null) takeSnapshot(failsafeSnapshotName);

   restore()
   ...
}
{code}

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Fix For: 0.98.0, 0.95.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-05-01 Thread Jonathan Hsieh (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13647045#comment-13647045
 ] 

Jonathan Hsieh commented on HBASE-8465:
---

This is why I wrote this comment:
https://issues.apache.org/jira/browse/HBASE-8465?focusedCommentId=13645603page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13645603

One underlying assumption is that snapshots are in a good state (they have to 
be to pass the verification step when taking a snapshot).  Operations working 
on a table can fail, and leave the table in a bad state (for example: master 
crash mid-restore, mid-alter).  Thus I think it is more likely to have a bad 
table than a bad snapshot.

Looking at the cases, it seems to make more sense to provide the admin the 
option to skip taking the snapshot (if our table is currently bad) so that we 
only have good snapshots.  Taking the snapshot and then deleting it seems like 
unnecessary work.  


 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Fix For: 0.98.0, 0.95.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-05-01 Thread Jonathan Hsieh (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13647047#comment-13647047
 ] 

Jonathan Hsieh commented on HBASE-8465:
---

Also since we have the table disabled, these operations are chainable enabling 
the admin to chose preferred behavior if we have a restore that doesn't take a 
snapshot.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Fix For: 0.98.0, 0.95.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-05-01 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13647057#comment-13647057
 ] 

Ted Yu commented on HBASE-8465:
---

bq. it is more likely to have a bad table than a bad snapshot.
Table being bad can mean two things: hbck would detect inconsistency or, table 
is in legitimate state but the data inside the table is not desirable. In the 
second case, taking rollback snapshot would help analyze how the table got into 
that state.

If we add takeSnapshot option, do we still need the dropRollbackSnapshot option 
(when takeSnapshot is true) ?

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Fix For: 0.98.0, 0.95.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-05-01 Thread Jonathan Hsieh (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13647064#comment-13647064
 ] 

Jonathan Hsieh commented on HBASE-8465:
---

bq. wait... instead of doing this at this point we should use String 
failsafeSnapshotName and have the default one in the default method...

[~mbertozzi] +1 for the ability to name the failsafe snapshot.  (nice name).  
I'm also agreeing the ability to optionally have a failsafe snapshot after a 
successful run make sense.  There are two options we are taking about here -- 
the case enumeration make me lean towards having the don't take the failsafe 
snapshot option over the always take and then delete the failsafe approach.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Fix For: 0.98.0, 0.95.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-05-01 Thread Jonathan Hsieh (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13647067#comment-13647067
 ] 

Jonathan Hsieh commented on HBASE-8465:
---

bq. Table being bad can mean two things: hbck would detect inconsistency or, 
table is in legitimate state but the data inside the table is not desirable. In 
the second case, taking rollback snapshot would help analyze how the table got 
into that state.

I believe currently if we fail mid-restore, we will be in a potentially bad 
data and bad metadata (a table with regions stuck with different schemas!).  
hbck can detectt this but I don't think it could really fix it.

bq. If we add takeSnapshot option, do we still need the dropRollbackSnapshot 
option (when takeSnapshot is true)?

Since we are disabled, and if we have the ability to specify the name of the 
failsafe snapshot, the admin can delete the failsafe before enabling the 
restored table.  So I don't think this is necessary to put all these options 
(e.g. both take failsafe and delete failsafe) into one command.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Fix For: 0.98.0, 0.95.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-04-30 Thread Matteo Bertozzi (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13645570#comment-13645570
 ] 

Matteo Bertozzi commented on HBASE-8465:


my guess is that we could add a new restoreSnapshot() with the new arg and the 
conf property for the default behavior.

{code}
restore(snapshotName) {
   restore(snapshotName, conf.get(...restore.drop.rollback))
}

restore(snapshotName, bool dropSnapshot) { ... }
{code}

Anyway I'm more for the reverse, adding a flag take snapshot instead of the 
drop rollback since the main idea of restore is that your table is broken... 
so taking a snapshot before restoring may not be useful and just wasting time.

+1 on changing the default name, or also making it configurable

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu

 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-04-30 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13645571#comment-13645571
 ] 

Ted Yu commented on HBASE-8465:
---

bq. make this a runtime restore snapshot parameter instead of a xml 
configuration option?
I thought adding a new 'rollback auto-drop' config parameter facilitates back 
compatibility.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu

 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-04-30 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13645575#comment-13645575
 ] 

Ted Yu commented on HBASE-8465:
---

bq. adding a flag take snapshot instead of the drop rollback
Interesting idea. +1

If Jon thinks the above is Okay, I will modify the subject one more time.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu

 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-04-30 Thread Jonathan Hsieh (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13645603#comment-13645603
 ] 

Jonathan Hsieh commented on HBASE-8465:
---

+1 for the runtime/xml conf behavior Matteo sketched.

On take snapshot vs drop rollback.  let's look at the use cases:
# table ok, use restore to get old data back.  Does it make sense to snapshot 
on restore?  Yes. 
# table ok, use restore to get old data back but it fails... (leads to next 
case)
# table broken, use restore to fix.   Does snapshotting on the next restore 
attempt make sense? (hm.. not really)
# table broken, using restore to get valid data back but it fails...  (go back 
to previous case).

As initially envisioned, the snapshot on restore wasn't for a fixup case, but 
for retaining healthy modifications before the restore.  In the cases of 
broken tables, cases 3,4 wants the ability to skip taking the snapshot.  I'd 
argue that case 1 is the common case -- and that case 3 and 4 are arguments for 
having an option for not snapshotting on restore. 

Dropping the rollback snapshot seems a little gratuitous -- we have the ability 
to do this with existing commands don't we?

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu

 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-04-30 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13645621#comment-13645621
 ] 

Ted Yu commented on HBASE-8465:
---

bq. we have the ability to do this with existing commands don't we?
The name of rollback snapshot is not returned. Person issuing restore command 
may not be aware of the existence of rollback snapshot. Later, when 
list_snapshots command reveals the rollback snapshots, people are surprised.
I think dropping the rollback snapshot is desirable.

I will provide a patch as outlined by Matteo above.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu

 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-04-30 Thread Matteo Bertozzi (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13645652#comment-13645652
 ] 

Matteo Bertozzi commented on HBASE-8465:


patch looks good to me, 
we have already other conf property name hardcoded in the Admin should we start 
to move them somewhere like HConfigurationConst or similar?
do you want also to include the rename of the rollbackSnapshot or is 
abandoned as idea?

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Attachments: 8465-trunk-v1.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-04-30 Thread Hadoop QA (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13645688#comment-13645688
 ] 

Hadoop QA commented on HBASE-8465:
--

{color:red}-1 overall{color}.  Here are the results of testing the latest 
attachment 
  http://issues.apache.org/jira/secure/attachment/12581176/8465-trunk-v1.txt
  against trunk revision .

{color:green}+1 @author{color}.  The patch does not contain any @author 
tags.

{color:red}-1 tests included{color}.  The patch doesn't appear to include 
any new or modified tests.
Please justify why no new tests are needed for this 
patch.
Also please list what manual steps were performed to 
verify this patch.

{color:green}+1 hadoop1.0{color}.  The patch compiles against the hadoop 
1.0 profile.

{color:green}+1 hadoop2.0{color}.  The patch compiles against the hadoop 
2.0 profile.

{color:green}+1 javadoc{color}.  The javadoc tool did not generate any 
warning messages.

{color:green}+1 javac{color}.  The applied patch does not increase the 
total number of javac compiler warnings.

{color:green}+1 findbugs{color}.  The patch does not introduce any new 
Findbugs (version 1.3.9) warnings.

{color:red}-1 release audit{color}.  The applied patch generated 1 release 
audit warnings (more than the trunk's current 0 warnings).

{color:green}+1 lineLengths{color}.  The patch does not introduce lines 
longer than 100

  {color:green}+1 site{color}.  The mvn site goal succeeds with this patch.

{color:green}+1 core tests{color}.  The patch passed unit tests in .

Test results: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5499//testReport/
Release audit warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5499//artifact/trunk/patchprocess/patchReleaseAuditProblems.txt
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5499//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-protocol.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5499//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-client.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5499//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-examples.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5499//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-hadoop1-compat.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5499//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-prefix-tree.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5499//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-common.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5499//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-server.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5499//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-hadoop-compat.html
Console output: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5499//console

This message is automatically generated.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-04-30 Thread Hadoop QA (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13645710#comment-13645710
 ] 

Hadoop QA commented on HBASE-8465:
--

{color:red}-1 overall{color}.  Here are the results of testing the latest 
attachment 
  http://issues.apache.org/jira/secure/attachment/12581179/8465-trunk-v2.txt
  against trunk revision .

{color:green}+1 @author{color}.  The patch does not contain any @author 
tags.

{color:red}-1 tests included{color}.  The patch doesn't appear to include 
any new or modified tests.
Please justify why no new tests are needed for this 
patch.
Also please list what manual steps were performed to 
verify this patch.

{color:green}+1 hadoop1.0{color}.  The patch compiles against the hadoop 
1.0 profile.

{color:green}+1 hadoop2.0{color}.  The patch compiles against the hadoop 
2.0 profile.

{color:green}+1 javadoc{color}.  The javadoc tool did not generate any 
warning messages.

{color:green}+1 javac{color}.  The applied patch does not increase the 
total number of javac compiler warnings.

{color:green}+1 findbugs{color}.  The patch does not introduce any new 
Findbugs (version 1.3.9) warnings.

{color:red}-1 release audit{color}.  The applied patch generated 1 release 
audit warnings (more than the trunk's current 0 warnings).

{color:green}+1 lineLengths{color}.  The patch does not introduce lines 
longer than 100

  {color:green}+1 site{color}.  The mvn site goal succeeds with this patch.

 {color:red}-1 core tests{color}.  The patch failed these unit tests:
   org.apache.hadoop.hbase.rest.client.TestRemoteAdmin

Test results: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5500//testReport/
Release audit warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5500//artifact/trunk/patchprocess/patchReleaseAuditProblems.txt
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5500//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-prefix-tree.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5500//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-client.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5500//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-common.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5500//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-protocol.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5500//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-server.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5500//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-hadoop1-compat.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5500//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-examples.html
Findbugs warnings: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5500//artifact/trunk/patchprocess/newPatchFindbugsWarningshbase-hadoop-compat.html
Console output: 
https://builds.apache.org/job/PreCommit-HBASE-Build/5500//console

This message is automatically generated.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-04-30 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13645739#comment-13645739
 ] 

Ted Yu commented on HBASE-8465:
---

The test passed locally:

Running org.apache.hadoop.hbase.rest.client.TestRemoteAdmin
2013-04-30 10:09:59.100 java[4325:1203] Unable to load realm info from 
SCDynamicStore
Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 15.158 sec

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-04-30 Thread Matteo Bertozzi (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13646000#comment-13646000
 ] 

Matteo Bertozzi commented on HBASE-8465:


+1 on v2 patch.

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Fix For: 0.98.0, 0.95.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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


[jira] [Commented] (HBASE-8465) Auto-drop rollback snapshot for snapshot restore

2013-04-30 Thread Ted Yu (JIRA)

[ 
https://issues.apache.org/jira/browse/HBASE-8465?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13646012#comment-13646012
 ] 

Ted Yu commented on HBASE-8465:
---

[~jmhsieh]:
Are you Okay with patch v2 ?

 Auto-drop rollback snapshot for snapshot restore
 

 Key: HBASE-8465
 URL: https://issues.apache.org/jira/browse/HBASE-8465
 Project: HBase
  Issue Type: Improvement
Reporter: Ted Yu
Assignee: Ted Yu
 Fix For: 0.98.0, 0.95.1

 Attachments: 8465-trunk-v1.txt, 8465-trunk-v2.txt


 Below is an excerpt from snapshot restore javadoc:
 {code}
* Restore the specified snapshot on the original table. (The table must be 
 disabled)
* Before restoring the table, a new snapshot with the current table state 
 is created.
* In case of failure, the table will be rolled back to the its original 
 state.
 {code}
 We can improve the handling of rollbackSnapshot in two ways:
 1. give better name to the rollbackSnapshot (adding 
 {code}'-for-rollback-'{code}). Currently the name is of the form:
 String rollbackSnapshot = snapshotName + - + 
 EnvironmentEdgeManager.currentTimeMillis();
 2. drop rollbackSnapshot at the end of restoreSnapshot() if the restore is 
 successful. We can introduce new config param, named 
 'hbase.snapshot.restore.drop.rollback', to keep compatibility with current 
 behavior.

--
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