Re: [PR] HBASE-29449 Update backup describe command for continuous backup [hbase]

2025-07-15 Thread via GitHub


taklwu merged PR #7045:
URL: https://github.com/apache/hbase/pull/7045


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] HBASE-29449 Update backup describe command for continuous backup [hbase]

2025-07-10 Thread via GitHub


Apache-HBase commented on PR #7045:
URL: https://github.com/apache/hbase/pull/7045#issuecomment-3058106042

   :broken_heart: **-1 overall**
   
   
   
   
   
   
   | Vote | Subsystem | Runtime |  Logfile | Comment |
   |::|--:|:|::|:---:|
   | +0 :ok: |  reexec  |   0m 34s |  |  Docker mode activated.  |
   | -0 :warning: |  yetus  |   0m  3s |  |  Unprocessed flag(s): 
--brief-report-file --spotbugs-strict-precheck --author-ignore-list 
--blanks-eol-ignore-file --blanks-tabs-ignore-file --quick-hadoopcheck  |
    _ Prechecks _ |
    _ HBASE-28957 Compile Tests _ |
   | +0 :ok: |  mvndep  |   0m  9s |  |  Maven dependency ordering for branch  |
   | +1 :green_heart: |  mvninstall  |   3m 17s |  |  HBASE-28957 passed  |
   | +1 :green_heart: |  compile  |   0m 52s |  |  HBASE-28957 passed  |
   | +1 :green_heart: |  javadoc  |   0m 24s |  |  HBASE-28957 passed  |
   | +1 :green_heart: |  shadedjars  |   6m  3s |  |  branch has no errors when 
building our shaded downstream artifacts.  |
   | -0 :warning: |  patch  |   6m 19s |  |  Used diff version of patch file. 
Binary files and potentially other changes not applied. Please rebase and 
squash commits if necessary.  |
    _ Patch Compile Tests _ |
   | +0 :ok: |  mvndep  |   0m 13s |  |  Maven dependency ordering for patch  |
   | +1 :green_heart: |  mvninstall  |   3m  5s |  |  the patch passed  |
   | +1 :green_heart: |  compile  |   0m 52s |  |  the patch passed  |
   | +1 :green_heart: |  javac  |   0m 52s |  |  the patch passed  |
   | +1 :green_heart: |  javadoc  |   0m 23s |  |  the patch passed  |
   | +1 :green_heart: |  shadedjars  |   6m  2s |  |  patch has no errors when 
building our shaded downstream artifacts.  |
    _ Other Tests _ |
   | +1 :green_heart: |  unit  |   0m 33s |  |  hbase-protocol-shaded in the 
patch passed.  |
   | -1 :x: |  unit  |  23m  4s | 
[/patch-unit-hbase-backup.txt](https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-7045/7/artifact/yetus-jdk17-hadoop3-check/output/patch-unit-hbase-backup.txt)
 |  hbase-backup in the patch failed.  |
   |  |   |  46m 39s |  |  |
   
   
   | Subsystem | Report/Notes |
   |--:|:-|
   | Docker | ClientAPI=1.43 ServerAPI=1.43 base: 
https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-7045/7/artifact/yetus-jdk17-hadoop3-check/output/Dockerfile
 |
   | GITHUB PR | https://github.com/apache/hbase/pull/7045 |
   | Optional Tests | javac javadoc unit compile shadedjars |
   | uname | Linux f9d1a2bd1741 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 
23 20:04:10 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux |
   | Build tool | maven |
   | Personality | dev-support/hbase-personality.sh |
   | git revision | HBASE-28957 / b16ebee2e9d531b75afccbde62ce6771e4f2077c |
   | Default Java | Eclipse Adoptium-17.0.11+9 |
   |  Test Results | 
https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-7045/7/testReport/
 |
   | Max. process+thread count | 3763 (vs. ulimit of 3) |
   | modules | C: hbase-protocol-shaded hbase-backup U: . |
   | Console output | 
https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-7045/7/console 
|
   | versions | git=2.34.1 maven=3.9.8 |
   | Powered by | Apache Yetus 0.15.0 https://yetus.apache.org |
   
   
   This message was automatically generated.
   
   


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] HBASE-29449 Update backup describe command for continuous backup [hbase]

2025-07-10 Thread via GitHub


Apache-HBase commented on PR #7045:
URL: https://github.com/apache/hbase/pull/7045#issuecomment-3058100216

   :confetti_ball: **+1 overall**
   
   
   
   
   
   
   | Vote | Subsystem | Runtime |  Logfile | Comment |
   |::|--:|:|::|:---:|
   | +0 :ok: |  reexec  |   0m 48s |  |  Docker mode activated.  |
    _ Prechecks _ |
   | +1 :green_heart: |  dupname  |   0m  0s |  |  No case conflicting files 
found.  |
   | +0 :ok: |  codespell  |   0m  1s |  |  codespell was not available.  |
   | +0 :ok: |  detsecrets  |   0m  1s |  |  detect-secrets was not available.  
|
   | +0 :ok: |  buf  |   0m  1s |  |  buf was not available.  |
   | +0 :ok: |  buf  |   0m  1s |  |  buf was not available.  |
   | +1 :green_heart: |  @author  |   0m  0s |  |  The patch does not contain 
any @author tags.  |
   | +1 :green_heart: |  hbaseanti  |   0m  0s |  |  Patch does not have any 
anti-patterns.  |
    _ HBASE-28957 Compile Tests _ |
   | +0 :ok: |  mvndep  |   0m 37s |  |  Maven dependency ordering for branch  |
   | +1 :green_heart: |  mvninstall  |   4m 18s |  |  HBASE-28957 passed  |
   | +1 :green_heart: |  compile  |   1m 33s |  |  HBASE-28957 passed  |
   | -0 :warning: |  checkstyle  |   0m 13s | 
[/buildtool-branch-checkstyle-hbase-backup.txt](https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-7045/7/artifact/yetus-general-check/output/buildtool-branch-checkstyle-hbase-backup.txt)
 |  The patch fails to run checkstyle in hbase-backup  |
   | +1 :green_heart: |  spotbugs  |   3m 33s |  |  HBASE-28957 passed  |
   | +1 :green_heart: |  spotless  |   0m 54s |  |  branch has no errors when 
running spotless:check.  |
   | -0 :warning: |  patch  |   1m  8s |  |  Used diff version of patch file. 
Binary files and potentially other changes not applied. Please rebase and 
squash commits if necessary.  |
    _ Patch Compile Tests _ |
   | +0 :ok: |  mvndep  |   0m 12s |  |  Maven dependency ordering for patch  |
   | +1 :green_heart: |  mvninstall  |   3m 41s |  |  the patch passed  |
   | +1 :green_heart: |  compile  |   1m 23s |  |  the patch passed  |
   | +1 :green_heart: |  cc  |   1m 23s |  |  the patch passed  |
   | -0 :warning: |  javac  |   0m 38s | 
[/results-compile-javac-hbase-backup.txt](https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-7045/7/artifact/yetus-general-check/output/results-compile-javac-hbase-backup.txt)
 |  hbase-backup generated 2 new + 116 unchanged - 0 fixed = 118 total (was 
116)  |
   | +1 :green_heart: |  blanks  |   0m  0s |  |  The patch has no blanks 
issues.  |
   | -0 :warning: |  checkstyle  |   0m 10s | 
[/buildtool-patch-checkstyle-hbase-backup.txt](https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-7045/7/artifact/yetus-general-check/output/buildtool-patch-checkstyle-hbase-backup.txt)
 |  The patch fails to run checkstyle in hbase-backup  |
   | +1 :green_heart: |  spotbugs  |   3m 25s |  |  the patch passed  |
   | +1 :green_heart: |  hadoopcheck  |  13m 16s |  |  Patch does not cause any 
errors with Hadoop 3.3.6 3.4.0.  |
   | +1 :green_heart: |  hbaseprotoc  |   1m  1s |  |  the patch passed  |
   | +1 :green_heart: |  spotless  |   0m 46s |  |  patch has no errors when 
running spotless:check.  |
    _ Other Tests _ |
   | +1 :green_heart: |  asflicense  |   0m 18s |  |  The patch does not 
generate ASF License warnings.  |
   |  |   |  44m 21s |  |  |
   
   
   | Subsystem | Report/Notes |
   |--:|:-|
   | Docker | ClientAPI=1.43 ServerAPI=1.43 base: 
https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-7045/7/artifact/yetus-general-check/output/Dockerfile
 |
   | GITHUB PR | https://github.com/apache/hbase/pull/7045 |
   | Optional Tests | dupname asflicense javac spotbugs checkstyle codespell 
detsecrets compile hadoopcheck hbaseanti spotless cc buflint bufcompat 
hbaseprotoc |
   | uname | Linux 628f586a8599 5.4.0-1103-aws #111~18.04.1-Ubuntu SMP Tue May 
23 20:04:10 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux |
   | Build tool | maven |
   | Personality | dev-support/hbase-personality.sh |
   | git revision | HBASE-28957 / b16ebee2e9d531b75afccbde62ce6771e4f2077c |
   | Default Java | Eclipse Adoptium-17.0.11+9 |
   | Max. process+thread count | 85 (vs. ulimit of 3) |
   | modules | C: hbase-protocol-shaded hbase-backup U: . |
   | Console output | 
https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-7045/7/console 
|
   | versions | git=2.34.1 maven=3.9.8 spotbugs=4.7.3 |
   | Powered by | Apache Yetus 0.15.0 https://yetus.apache.org |
   
   
   This message was automatically generated.
   
   


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



Re: [PR] HBASE-29449 Update backup describe command for continuous backup [hbase]

2025-07-10 Thread via GitHub


ankitsol commented on code in PR #7045:
URL: https://github.com/apache/hbase/pull/7045#discussion_r2198093485


##
hbase-backup/src/test/java/org/apache/hadoop/hbase/backup/TestBackupDescribe.java:
##
@@ -101,11 +106,58 @@ public void testBackupDescribeCommand() throws Exception {
 String response = baos.toString();
 assertTrue(response.indexOf(backupId) > 0);
 assertTrue(response.indexOf("COMPLETE") > 0);
+assertTrue(response.contains("IsContinuous=false"));
 
 BackupSystemTable table = new BackupSystemTable(TEST_UTIL.getConnection());
 BackupInfo status = table.readBackupInfo(backupId);
 String desc = status.getShortDescription();
 table.close();
 assertTrue(response.indexOf(desc) >= 0);
   }
+
+  @Test
+  public void testBackupDescribeCommandForContinuousBackup() throws Exception {
+LOG.info("test backup describe on a single table with data: command-line");
+Path root = TEST_UTIL.getDataTestDirOnTestFS();
+Path backupWalDir = new Path(root, "testBackupDescribeCommand");
+FileSystem fs = FileSystem.get(conf1);
+fs.mkdirs(backupWalDir);
+conf1.set(CONF_CONTINUOUS_BACKUP_WAL_DIR, backupWalDir.toString());
+
+try (BackupSystemTable table = new 
BackupSystemTable(TEST_UTIL.getConnection())) {
+  String[] backupArgs = new String[] { "create", BackupType.FULL.name(), 
BACKUP_ROOT_DIR, "-t",
+table2.getNameAsString(), "-" + OPTION_ENABLE_CONTINUOUS_BACKUP };
+  int ret = ToolRunner.run(conf1, new BackupDriver(), backupArgs);
+  assertEquals("Backup should succeed", 0, ret);
+  List backups = table.getBackupHistory();
+  String backupId = backups.get(0).getBackupId();
+  assertTrue(checkSucceeded(backupId));
+  LOG.info("backup complete");
+
+  BackupInfo info = getBackupAdmin().getBackupInfo(backupId);
+  assertTrue(info.getState() == BackupState.COMPLETE);
+
+  ByteArrayOutputStream baos = new ByteArrayOutputStream();
+  System.setOut(new PrintStream(baos));
+
+  String[] args = new String[] { "describe", backupId };
+  // Run backup
+  ret = ToolRunner.run(conf1, new BackupDriver(), args);
+  assertTrue(ret == 0);
+  String response = baos.toString();
+  assertTrue(response.indexOf(backupId) > 0);
+  assertTrue(response.indexOf("COMPLETE") > 0);
+  assertTrue(response.contains("IsContinuous=true"));
+
+  BackupInfo status = table.readBackupInfo(backupId);

Review Comment:
   Makes sense, added now



##
hbase-backup/src/test/java/org/apache/hadoop/hbase/backup/TestBackupDescribe.java:
##
@@ -101,11 +106,58 @@ public void testBackupDescribeCommand() throws Exception {
 String response = baos.toString();
 assertTrue(response.indexOf(backupId) > 0);
 assertTrue(response.indexOf("COMPLETE") > 0);
+assertTrue(response.contains("IsContinuous=false"));
 
 BackupSystemTable table = new BackupSystemTable(TEST_UTIL.getConnection());
 BackupInfo status = table.readBackupInfo(backupId);
 String desc = status.getShortDescription();
 table.close();
 assertTrue(response.indexOf(desc) >= 0);
   }
+
+  @Test
+  public void testBackupDescribeCommandForContinuousBackup() throws Exception {
+LOG.info("test backup describe on a single table with data: command-line");
+Path root = TEST_UTIL.getDataTestDirOnTestFS();
+Path backupWalDir = new Path(root, "testBackupDescribeCommand");
+FileSystem fs = FileSystem.get(conf1);
+fs.mkdirs(backupWalDir);
+conf1.set(CONF_CONTINUOUS_BACKUP_WAL_DIR, backupWalDir.toString());
+
+try (BackupSystemTable table = new 
BackupSystemTable(TEST_UTIL.getConnection())) {
+  String[] backupArgs = new String[] { "create", BackupType.FULL.name(), 
BACKUP_ROOT_DIR, "-t",
+table2.getNameAsString(), "-" + OPTION_ENABLE_CONTINUOUS_BACKUP };
+  int ret = ToolRunner.run(conf1, new BackupDriver(), backupArgs);
+  assertEquals("Backup should succeed", 0, ret);
+  List backups = table.getBackupHistory();
+  String backupId = backups.get(0).getBackupId();
+  assertTrue(checkSucceeded(backupId));
+  LOG.info("backup complete");
+
+  BackupInfo info = getBackupAdmin().getBackupInfo(backupId);
+  assertTrue(info.getState() == BackupState.COMPLETE);
+
+  ByteArrayOutputStream baos = new ByteArrayOutputStream();
+  System.setOut(new PrintStream(baos));
+
+  String[] args = new String[] { "describe", backupId };
+  // Run backup
+  ret = ToolRunner.run(conf1, new BackupDriver(), args);
+  assertTrue(ret == 0);
+  String response = baos.toString();
+  assertTrue(response.indexOf(backupId) > 0);
+  assertTrue(response.indexOf("COMPLETE") > 0);

Review Comment:
   Sure



-- 
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: [email protected]

For q

Re: [PR] HBASE-29449 Update backup describe command for continuous backup [hbase]

2025-07-10 Thread via GitHub


ankitsol commented on PR #7045:
URL: https://github.com/apache/hbase/pull/7045#issuecomment-3057919893

   Created subtask https://issues.apache.org/jira/browse/HBASE-29449 for "hbase 
backup describe" command 


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]