You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by GitBox <gi...@apache.org> on 2022/08/11 10:13:23 UTC

[GitHub] [hbase] alexdongli0829 commented on a diff in pull request #4661: [HBASE-27245]Expose the archive API to the end user

alexdongli0829 commented on code in PR #4661:
URL: https://github.com/apache/hbase/pull/4661#discussion_r943319819


##########
hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java:
##########
@@ -2431,11 +2431,35 @@ private static boolean isCatalogTable(final TableName tableName) {
     return tableName.equals(TableName.META_TABLE_NAME);
   }
 
+  private void checkSnapshot(TableName tableName, boolean archive) throws IOException {
+    /*
+     * If decide to delete the table without archive, need to make sure the table has no snapshot
+     * Meanwhile, the check will scan the snapshots which will do list and open, if there is lots of
+     * snapshot, the performance may be impacted, should evaluate the performance between directly
+     * archive and snapshot scan TODO: find some any way to get if the table snapshotted or not
+     */
+    if (!archive) {

Review Comment:
   @Apache9 Thanks so much for your time. The thought is because there will be no archive for all the hfiles, so if there are any snapshots, the snapshots will be broken, so to avoid the broken, I made the check before conduct the actual delete without archive, make sense?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@hbase.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org