hbase icon indicating copy to clipboard operation
hbase copied to clipboard

HBASE-28882 Backup restores are broken if the backup has moved locations

Open rmdmattingly opened this issue 1 year ago • 20 comments

https://issues.apache.org/jira/browse/HBASE-28882

My company runs a few hundred HBase clusters. We want to take backups everyday in one public cloud region, and then use said cloud's native replication solution to "backup our backups" in a secondary region. This is how we plan for region-wide disaster recovery.

This system should work, but doesn't because of the way that BackupManifests are constructed.

Backing up a bit (no pun intended): when we replicate backups verbatim, the manifest file continues to point to the original backup root. This shouldn't matter, because when taking a restore one passes a RestoreRequest to the RestoreTablesClient — and this RestoreRequest includes a BackupRootDir field. This works as you would expect initially, but eventually we build a BackupManifest that fails to interpolate this provided root directory and, instead, falls back to what it finds on disk in the backup (which would point back to the primary backup location, even if reading a replicated backup).

To fix this, I'm proposing that we properly interpolate the request's root directory field when building BackupManifests.

I've added a unit test for the new behavior, and I've used this updated client to successfully run a table restore of a replicated backup in our test environment.

cc @ndimiduk @charlesconnell @aalhour @ksravista @DieterDP-ng

rmdmattingly avatar Sep 24 '24 20:09 rmdmattingly

:broken_heart: -1 overall

Vote Subsystem Runtime Logfile Comment
+0 :ok: reexec 0m 41s Docker mode activated.
_ Prechecks _
+1 :green_heart: dupname 0m 0s No case conflicting files found.
+0 :ok: codespell 0m 0s codespell was not available.
+0 :ok: detsecrets 0m 0s detect-secrets 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.
_ master Compile Tests _
+1 :green_heart: mvninstall 3m 5s master passed
+1 :green_heart: compile 0m 32s master passed
+1 :green_heart: checkstyle 0m 12s master passed
+1 :green_heart: spotbugs 0m 32s master passed
+1 :green_heart: spotless 0m 46s branch has no errors when running spotless:check.
_ Patch Compile Tests _
-1 :x: mvninstall 2m 55s /patch-mvninstall-root.txt root in the patch failed.
-1 :x: compile 0m 11s /patch-compile-hbase-backup.txt hbase-backup in the patch failed.
-0 :warning: javac 0m 11s /patch-compile-hbase-backup.txt hbase-backup in the patch failed.
+1 :green_heart: blanks 0m 0s The patch has no blanks issues.
-0 :warning: checkstyle 0m 11s /results-checkstyle-hbase-backup.txt hbase-backup: The patch generated 2 new + 0 unchanged - 0 fixed = 2 total (was 0)
-1 :x: spotbugs 0m 11s /patch-spotbugs-hbase-backup.txt hbase-backup in the patch failed.
-1 :x: hadoopcheck 2m 32s The patch causes 10 errors with Hadoop v3.3.6.
-1 :x: hadoopcheck 5m 7s The patch causes 10 errors with Hadoop v3.4.0.
+1 :green_heart: spotless 0m 44s patch has no errors when running spotless:check.
_ Other Tests _
+1 :green_heart: asflicense 0m 10s The patch does not generate ASF License warnings.
16m 26s
Subsystem Report/Notes
Docker ClientAPI=1.47 ServerAPI=1.47 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/1/artifact/yetus-general-check/output/Dockerfile
GITHUB PR https://github.com/apache/hbase/pull/6294
Optional Tests dupname asflicense javac spotbugs checkstyle codespell detsecrets compile hadoopcheck hbaseanti spotless
uname Linux ec5e5a26418f 5.4.0-195-generic #215-Ubuntu SMP Fri Aug 2 18:28:05 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/hbase-personality.sh
git revision master / 7cdd9ee299cebb658c3f83573197160d2d3db902
Default Java Eclipse Adoptium-17.0.11+9
hadoopcheck https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/1/artifact/yetus-general-check/output/patch-javac-3.3.6.txt
hadoopcheck https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/1/artifact/yetus-general-check/output/patch-javac-3.4.0.txt
Max. process+thread count 83 (vs. ulimit of 30000)
modules C: hbase-backup U: hbase-backup
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/1/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.

Apache-HBase avatar Sep 24 '24 21:09 Apache-HBase

:broken_heart: -1 overall

Vote Subsystem Runtime Logfile Comment
+0 :ok: reexec 0m 26s 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 _
_ master Compile Tests _
+1 :green_heart: mvninstall 3m 13s master passed
+1 :green_heart: compile 0m 19s master passed
+1 :green_heart: javadoc 0m 14s master passed
+1 :green_heart: shadedjars 5m 43s branch has no errors when building our shaded downstream artifacts.
_ Patch Compile Tests _
-1 :x: mvninstall 3m 0s /patch-mvninstall-root.txt root in the patch failed.
-1 :x: compile 0m 10s /patch-compile-hbase-backup.txt hbase-backup in the patch failed.
-0 :warning: javac 0m 10s /patch-compile-hbase-backup.txt hbase-backup in the patch failed.
+1 :green_heart: javadoc 0m 13s the patch passed
+1 :green_heart: shadedjars 5m 41s patch has no errors when building our shaded downstream artifacts.
_ Other Tests _
-1 :x: unit 0m 10s /patch-unit-hbase-backup.txt hbase-backup in the patch failed.
20m 1s
Subsystem Report/Notes
Docker ClientAPI=1.43 ServerAPI=1.43 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/1/artifact/yetus-jdk17-hadoop3-check/output/Dockerfile
GITHUB PR https://github.com/apache/hbase/pull/6294
Optional Tests javac javadoc unit compile shadedjars
uname Linux 7f8d26d27a80 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 master / 7cdd9ee299cebb658c3f83573197160d2d3db902
Default Java Eclipse Adoptium-17.0.11+9
Test Results https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/1/testReport/
Max. process+thread count 83 (vs. ulimit of 30000)
modules C: hbase-backup U: hbase-backup
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/1/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.

Apache-HBase avatar Sep 24 '24 21:09 Apache-HBase

:broken_heart: -1 overall

Vote Subsystem Runtime Logfile Comment
+0 :ok: reexec 0m 43s Docker mode activated.
_ Prechecks _
+1 :green_heart: dupname 0m 0s No case conflicting files found.
+0 :ok: codespell 0m 0s codespell was not available.
+0 :ok: detsecrets 0m 0s detect-secrets 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.
_ master Compile Tests _
+1 :green_heart: mvninstall 3m 1s master passed
+1 :green_heart: compile 0m 31s master passed
+1 :green_heart: checkstyle 0m 12s master passed
+1 :green_heart: spotbugs 0m 33s master passed
+1 :green_heart: spotless 0m 46s branch has no errors when running spotless:check.
_ Patch Compile Tests _
+1 :green_heart: mvninstall 2m 54s the patch passed
-1 :x: compile 0m 24s /patch-compile-hbase-backup.txt hbase-backup in the patch failed.
-0 :warning: javac 0m 24s /patch-compile-hbase-backup.txt hbase-backup in the patch failed.
+1 :green_heart: blanks 0m 0s The patch has no blanks issues.
-0 :warning: checkstyle 0m 11s /results-checkstyle-hbase-backup.txt hbase-backup: The patch generated 2 new + 0 unchanged - 0 fixed = 2 total (was 0)
+1 :green_heart: spotbugs 0m 41s the patch passed
+1 :green_heart: hadoopcheck 10m 35s Patch does not cause any errors with Hadoop 3.3.6 3.4.0.
-1 :x: spotless 0m 41s patch has 27 errors when running spotless:check, run spotless:apply to fix.
_ Other Tests _
+1 :green_heart: asflicense 0m 11s The patch does not generate ASF License warnings.
27m 44s
Subsystem Report/Notes
Docker ClientAPI=1.47 ServerAPI=1.47 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/2/artifact/yetus-general-check/output/Dockerfile
GITHUB PR https://github.com/apache/hbase/pull/6294
Optional Tests dupname asflicense javac spotbugs checkstyle codespell detsecrets compile hadoopcheck hbaseanti spotless
uname Linux c9e7f0caaeba 5.4.0-195-generic #215-Ubuntu SMP Fri Aug 2 18:28:05 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/hbase-personality.sh
git revision master / bcbd12980942946d48adb40898746d8239230464
Default Java Eclipse Adoptium-17.0.11+9
spotless https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/2/artifact/yetus-general-check/output/patch-spotless.txt
Max. process+thread count 83 (vs. ulimit of 30000)
modules C: hbase-backup U: hbase-backup
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/2/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.

Apache-HBase avatar Sep 24 '24 23:09 Apache-HBase

:broken_heart: -1 overall

Vote Subsystem Runtime Logfile Comment
+0 :ok: reexec 0m 39s 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 _
_ master Compile Tests _
+1 :green_heart: mvninstall 3m 14s master passed
+1 :green_heart: compile 0m 19s master passed
+1 :green_heart: javadoc 0m 14s master passed
+1 :green_heart: shadedjars 5m 46s branch has no errors when building our shaded downstream artifacts.
_ Patch Compile Tests _
+1 :green_heart: mvninstall 3m 5s the patch passed
+1 :green_heart: compile 0m 18s the patch passed
+1 :green_heart: javac 0m 18s the patch passed
+1 :green_heart: javadoc 0m 13s the patch passed
+1 :green_heart: shadedjars 5m 44s patch has no errors when building our shaded downstream artifacts.
_ Other Tests _
-1 :x: unit 10m 5s /patch-unit-hbase-backup.txt hbase-backup in the patch failed.
30m 29s
Subsystem Report/Notes
Docker ClientAPI=1.43 ServerAPI=1.43 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/2/artifact/yetus-jdk17-hadoop3-check/output/Dockerfile
GITHUB PR https://github.com/apache/hbase/pull/6294
Optional Tests javac javadoc unit compile shadedjars
uname Linux 238a418d62d9 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 master / bcbd12980942946d48adb40898746d8239230464
Default Java Eclipse Adoptium-17.0.11+9
Test Results https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/2/testReport/
Max. process+thread count 3846 (vs. ulimit of 30000)
modules C: hbase-backup U: hbase-backup
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/2/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.

Apache-HBase avatar Sep 24 '24 23:09 Apache-HBase

A question (before having had the time to go through your changes): When testing backup functionality for my company, I believe I tested the ability to restore a backup on a new (empty) HBase cluster, which worked as expected. So a restore should be possible without using any local BackupInfo on the target cluster. But this PR seems to imply that local BackupInfo is in fact used. Is this a case of use-if-present, or am I missing something?

DieterDP-ng avatar Sep 25 '24 08:09 DieterDP-ng

Did your test also involve moving the backup location? For example, moving the backup from an S3 bucket in us-east-1 to us-east-2 prior to attempting the restore?

Edit to clarify further: the simple backup case that you've described above definitely does work. Taking a backup and then restoring from that backup works well. But the more complicated case of:

  1. Take a backup
  2. Move that backup's location
  3. Initiate a restore specifying the new location

Does not work because we stop using the specified location at this point in the restore internals.

rmdmattingly avatar Sep 25 '24 09:09 rmdmattingly

Converting to a draft PR while I investigate what looks like a related test failures (testBackupHistory)

Edit: I made a precondition too strict for the variety of paths that might be passed into a BackupManifest constructor. Working on an update now, and will test more thoroughly locally

rmdmattingly avatar Sep 25 '24 09:09 rmdmattingly

Did your test also involve moving the backup location? For example, moving the backup from an S3 bucket in us-east-1 to us-east-2 prior to attempting the restore?

No, my testcase was "can a fresh HBase cluster restore a backup".

Does not work because we stop using the specified location at this point in the restore internals.

This is where I'm confused. A fresh cluster won't have any record stored of where backups were previously stored. So why is this an issue for a cluster that created the now-moved backup? (To be clear: I believe you saying this is an issue, I just don't understand yet where it comes from.)

DieterDP-ng avatar Sep 25 '24 12:09 DieterDP-ng

No, my testcase was "can a fresh HBase cluster restore a backup".

👍

fresh cluster won't have any record stored of where backups were previously stored. So why is this an issue for a cluster that created the now-moved backup?

This is a good question that I don't have a certain answer to because the test that I'm running internally actually restores to the existing cluster in-place (it drops the existing table, and then restores from backup).

But I believe it would still be a problem for a restore to a new cluster because we don't load the backup manifest from metadata on the HBase cluster — we load the backup manifest from its on disk persistence in the given backup.

          // load and set manifest field from file content
          long len = subFile.getLen();
          byte[] pbBytes = new byte[(int) len];
          try (FSDataInputStream in = fs.open(subFile.getPath())) {
            in.readFully(pbBytes);
          } catch (IOException e) {
            throw new BackupException(e.getMessage());
          }
          BackupProtos.BackupImage proto = null;
          try {
            proto = BackupProtos.BackupImage.parseFrom(pbBytes);
          } catch (Exception e) {
            throw new BackupException(e);
          }

For example:

  1. cluster-a takes a backup and persists it to /primary/root/dir
  2. we move that backup to /secondary/root/dir, verbatim, via S3 replication (or something similar)
  3. we decide we want to restore this backup onto cluster-b
  4. we send a restore request to cluster-b for this backup, with the root dir specified as /secondary/root/dir
  5. the restore will read the BackupManifest file from /secondary/root/dir, as intended, but in the aforementioned code we'll blindly parse a proto that has the root dir listed as /primary/root/dir, both for its own BackupImage and all of the ancestor images
  6. the restore will now run awry with an unclear/inconsistent root dir. Maybe it would succeed if your primary root dir still worked, the backup is still there, and your permissions allow access to both — but I don't think that "success" really aligns with the operator's intention of passing in the secondary root. And, more likely, it will fail because you've passed in a secondary root for a reason (perhaps the primary root dir is down, due to a region outage for example. Or perhaps you just enforce good least privilege)

This PR fixes this by intervening in step 5. After we parse the proto we'll hydrate the BackupImage (and its ancestors) with the backup root that was passed into the constructor, and that ensures that we stay aligned on one root

rmdmattingly avatar Sep 25 '24 12:09 rmdmattingly

:broken_heart: -1 overall

Vote Subsystem Runtime Logfile Comment
+0 :ok: reexec 0m 41s Docker mode activated.
_ Prechecks _
+1 :green_heart: dupname 0m 0s No case conflicting files found.
+0 :ok: codespell 0m 0s codespell was not available.
+0 :ok: detsecrets 0m 0s detect-secrets 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.
_ master Compile Tests _
+1 :green_heart: mvninstall 3m 27s master passed
+1 :green_heart: compile 0m 35s master passed
+1 :green_heart: checkstyle 0m 14s master passed
+1 :green_heart: spotbugs 0m 41s master passed
+1 :green_heart: spotless 1m 17s branch has no errors when running spotless:check.
_ Patch Compile Tests _
+1 :green_heart: mvninstall 4m 59s the patch passed
-1 :x: compile 0m 45s /patch-compile-hbase-backup.txt hbase-backup in the patch failed.
-0 :warning: javac 0m 45s /patch-compile-hbase-backup.txt hbase-backup in the patch failed.
+1 :green_heart: blanks 0m 0s The patch has no blanks issues.
-0 :warning: checkstyle 0m 22s /results-checkstyle-hbase-backup.txt hbase-backup: The patch generated 1 new + 0 unchanged - 0 fixed = 1 total (was 0)
+1 :green_heart: spotbugs 1m 25s the patch passed
+1 :green_heart: hadoopcheck 17m 1s Patch does not cause any errors with Hadoop 3.3.6 3.4.0.
+1 :green_heart: spotless 1m 14s patch has no errors when running spotless:check.
_ Other Tests _
+1 :green_heart: asflicense 0m 15s The patch does not generate ASF License warnings.
43m 7s
Subsystem Report/Notes
Docker ClientAPI=1.47 ServerAPI=1.47 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/3/artifact/yetus-general-check/output/Dockerfile
GITHUB PR https://github.com/apache/hbase/pull/6294
Optional Tests dupname asflicense javac spotbugs checkstyle codespell detsecrets compile hadoopcheck hbaseanti spotless
uname Linux 9c8313e05ba7 5.4.0-195-generic #215-Ubuntu SMP Fri Aug 2 18:28:05 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/hbase-personality.sh
git revision master / 78080c3aa8caab37983d24bd3c06d5a65434fa69
Default Java Eclipse Adoptium-17.0.11+9
Max. process+thread count 83 (vs. ulimit of 30000)
modules C: hbase-backup U: hbase-backup
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/3/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.

Apache-HBase avatar Sep 25 '24 16:09 Apache-HBase

:broken_heart: -1 overall

Vote Subsystem Runtime Logfile Comment
+0 :ok: reexec 0m 29s Docker mode activated.
-0 :warning: yetus 0m 2s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --author-ignore-list --blanks-eol-ignore-file --blanks-tabs-ignore-file --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+1 :green_heart: mvninstall 3m 26s master passed
+1 :green_heart: compile 0m 19s master passed
+1 :green_heart: javadoc 0m 15s master passed
+1 :green_heart: shadedjars 5m 59s branch has no errors when building our shaded downstream artifacts.
_ Patch Compile Tests _
+1 :green_heart: mvninstall 3m 14s the patch passed
+1 :green_heart: compile 0m 20s the patch passed
+1 :green_heart: javac 0m 20s the patch passed
+1 :green_heart: javadoc 0m 14s the patch passed
+1 :green_heart: shadedjars 6m 52s patch has no errors when building our shaded downstream artifacts.
_ Other Tests _
-1 :x: unit 12m 45s /patch-unit-hbase-backup.txt hbase-backup in the patch failed.
34m 48s
Subsystem Report/Notes
Docker ClientAPI=1.43 ServerAPI=1.43 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/3/artifact/yetus-jdk17-hadoop3-check/output/Dockerfile
GITHUB PR https://github.com/apache/hbase/pull/6294
Optional Tests javac javadoc unit compile shadedjars
uname Linux 711f3d449090 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 master / 78080c3aa8caab37983d24bd3c06d5a65434fa69
Default Java Eclipse Adoptium-17.0.11+9
Test Results https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/3/testReport/
Max. process+thread count 3846 (vs. ulimit of 30000)
modules C: hbase-backup U: hbase-backup
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/3/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.

Apache-HBase avatar Sep 25 '24 16:09 Apache-HBase

:confetti_ball: +1 overall

Vote Subsystem Runtime Logfile Comment
+0 :ok: reexec 0m 29s Docker mode activated.
_ Prechecks _
+1 :green_heart: dupname 0m 0s No case conflicting files found.
+0 :ok: codespell 0m 0s codespell was not available.
+0 :ok: detsecrets 0m 0s detect-secrets 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.
_ master Compile Tests _
+1 :green_heart: mvninstall 2m 55s master passed
+1 :green_heart: compile 0m 29s master passed
+1 :green_heart: checkstyle 0m 10s master passed
+1 :green_heart: spotbugs 0m 29s master passed
+1 :green_heart: spotless 0m 44s branch has no errors when running spotless:check.
_ Patch Compile Tests _
+1 :green_heart: mvninstall 2m 53s the patch passed
+1 :green_heart: compile 0m 28s the patch passed
-0 :warning: javac 0m 28s /results-compile-javac-hbase-backup.txt hbase-backup generated 1 new + 101 unchanged - 0 fixed = 102 total (was 101)
+1 :green_heart: blanks 0m 0s The patch has no blanks issues.
-0 :warning: checkstyle 0m 9s /results-checkstyle-hbase-backup.txt hbase-backup: The patch generated 1 new + 0 unchanged - 0 fixed = 1 total (was 0)
+1 :green_heart: spotbugs 0m 35s the patch passed
+1 :green_heart: hadoopcheck 11m 1s Patch does not cause any errors with Hadoop 3.3.6 3.4.0.
+1 :green_heart: spotless 0m 43s patch has no errors when running spotless:check.
_ Other Tests _
+1 :green_heart: asflicense 0m 9s The patch does not generate ASF License warnings.
27m 58s
Subsystem Report/Notes
Docker ClientAPI=1.43 ServerAPI=1.43 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/4/artifact/yetus-general-check/output/Dockerfile
GITHUB PR https://github.com/apache/hbase/pull/6294
Optional Tests dupname asflicense javac spotbugs checkstyle codespell detsecrets compile hadoopcheck hbaseanti spotless
uname Linux 380dd9c40d60 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 master / 8ba12e24dadab7a8771c93639ac5cf6fe8c069b3
Default Java Eclipse Adoptium-17.0.11+9
Max. process+thread count 83 (vs. ulimit of 30000)
modules C: hbase-backup U: hbase-backup
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/4/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.

Apache-HBase avatar Sep 25 '24 17:09 Apache-HBase

:confetti_ball: +1 overall

Vote Subsystem Runtime Logfile Comment
+0 :ok: reexec 0m 28s Docker mode activated.
-0 :warning: yetus 0m 2s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --author-ignore-list --blanks-eol-ignore-file --blanks-tabs-ignore-file --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+1 :green_heart: mvninstall 3m 18s master passed
+1 :green_heart: compile 0m 19s master passed
+1 :green_heart: javadoc 0m 14s master passed
+1 :green_heart: shadedjars 5m 51s branch has no errors when building our shaded downstream artifacts.
_ Patch Compile Tests _
+1 :green_heart: mvninstall 3m 11s the patch passed
+1 :green_heart: compile 0m 19s the patch passed
+1 :green_heart: javac 0m 19s the patch passed
+1 :green_heart: javadoc 0m 14s the patch passed
+1 :green_heart: shadedjars 5m 51s patch has no errors when building our shaded downstream artifacts.
_ Other Tests _
+1 :green_heart: unit 10m 58s hbase-backup in the patch passed.
31m 39s
Subsystem Report/Notes
Docker ClientAPI=1.43 ServerAPI=1.43 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/4/artifact/yetus-jdk17-hadoop3-check/output/Dockerfile
GITHUB PR https://github.com/apache/hbase/pull/6294
Optional Tests javac javadoc unit compile shadedjars
uname Linux b014eba18b0d 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 master / 8ba12e24dadab7a8771c93639ac5cf6fe8c069b3
Default Java Eclipse Adoptium-17.0.11+9
Test Results https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/4/testReport/
Max. process+thread count 3857 (vs. ulimit of 30000)
modules C: hbase-backup U: hbase-backup
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/4/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.

Apache-HBase avatar Sep 25 '24 17:09 Apache-HBase

:confetti_ball: +1 overall

Vote Subsystem Runtime Logfile Comment
+0 :ok: reexec 0m 30s Docker mode activated.
_ Prechecks _
+1 :green_heart: dupname 0m 0s No case conflicting files found.
+0 :ok: codespell 0m 0s codespell was not available.
+0 :ok: detsecrets 0m 0s detect-secrets 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.
_ master Compile Tests _
+1 :green_heart: mvninstall 3m 18s master passed
+1 :green_heart: compile 0m 29s master passed
+1 :green_heart: checkstyle 0m 10s master passed
+1 :green_heart: spotbugs 0m 31s master passed
+1 :green_heart: spotless 0m 46s branch has no errors when running spotless:check.
_ Patch Compile Tests _
+1 :green_heart: mvninstall 3m 4s the patch passed
+1 :green_heart: compile 0m 27s the patch passed
+1 :green_heart: javac 0m 27s the patch passed
+1 :green_heart: blanks 0m 0s The patch has no blanks issues.
+1 :green_heart: checkstyle 0m 8s the patch passed
+1 :green_heart: spotbugs 0m 35s the patch passed
+1 :green_heart: hadoopcheck 11m 42s Patch does not cause any errors with Hadoop 3.3.6 3.4.0.
+1 :green_heart: spotless 0m 44s patch has no errors when running spotless:check.
_ Other Tests _
+1 :green_heart: asflicense 0m 10s The patch does not generate ASF License warnings.
29m 39s
Subsystem Report/Notes
Docker ClientAPI=1.43 ServerAPI=1.43 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/5/artifact/yetus-general-check/output/Dockerfile
GITHUB PR https://github.com/apache/hbase/pull/6294
Optional Tests dupname asflicense javac spotbugs checkstyle codespell detsecrets compile hadoopcheck hbaseanti spotless
uname Linux e09ae84e450f 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 master / 2d6e9a865e58fbb9b22d763efa9bf58b13762f14
Default Java Eclipse Adoptium-17.0.11+9
Max. process+thread count 83 (vs. ulimit of 30000)
modules C: hbase-backup U: hbase-backup
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/5/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.

Apache-HBase avatar Sep 26 '24 19:09 Apache-HBase

:confetti_ball: +1 overall

Vote Subsystem Runtime Logfile Comment
+0 :ok: reexec 0m 38s Docker mode activated.
-0 :warning: yetus 0m 2s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --author-ignore-list --blanks-eol-ignore-file --blanks-tabs-ignore-file --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+1 :green_heart: mvninstall 4m 1s master passed
+1 :green_heart: compile 0m 25s master passed
+1 :green_heart: javadoc 0m 19s master passed
+1 :green_heart: shadedjars 6m 18s branch has no errors when building our shaded downstream artifacts.
_ Patch Compile Tests _
+1 :green_heart: mvninstall 3m 49s the patch passed
+1 :green_heart: compile 0m 23s the patch passed
+1 :green_heart: javac 0m 23s the patch passed
+1 :green_heart: javadoc 0m 16s the patch passed
+1 :green_heart: shadedjars 6m 10s patch has no errors when building our shaded downstream artifacts.
_ Other Tests _
+1 :green_heart: unit 11m 45s hbase-backup in the patch passed.
35m 12s
Subsystem Report/Notes
Docker ClientAPI=1.47 ServerAPI=1.47 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/5/artifact/yetus-jdk17-hadoop3-check/output/Dockerfile
GITHUB PR https://github.com/apache/hbase/pull/6294
Optional Tests javac javadoc unit compile shadedjars
uname Linux 6b38f81c4be2 5.4.0-192-generic #212-Ubuntu SMP Fri Jul 5 09:47:39 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/hbase-personality.sh
git revision master / 2d6e9a865e58fbb9b22d763efa9bf58b13762f14
Default Java Eclipse Adoptium-17.0.11+9
Test Results https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/5/testReport/
Max. process+thread count 3466 (vs. ulimit of 30000)
modules C: hbase-backup U: hbase-backup
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/5/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.

Apache-HBase avatar Sep 26 '24 19:09 Apache-HBase

Browsed the code, looks good to me.

I now also get why this wasn't an issue for my tests when restoring a backup on a fresh cluster: the backup root hadn't changed in that case, so the paths in the backup manifests were still correct.

We could go one step further though. The core issue is that the protofied(?) BackupImage, which is stored as the backup manifest on the filesystem, contains it's own path. So, it would make sense to simply not store the path. This would imply losing the functionality that the ancestors of a backup B could have different backuproots than B, but there's currently no functionality to create such backups, so that's not a real loss. I glanced the code, and found no real need to persist the backuproot path.

DieterDP-ng avatar Oct 02 '24 09:10 DieterDP-ng

Good idea, I don't obviously see a reason to persist the root on the BackupImage either, and any subtraction in this code is a big addition imo. I'll take a look at cleaning that up

rmdmattingly avatar Oct 02 '24 09:10 rmdmattingly

@DieterDP-ng I've thought about it a little bit more, and I'm less sure about taking the path out of the BackupManifest. I like that the backups can be used, even if the original cluster and/or its backup system table has been lost.

If we removed this metadata from the backup itself, and the system table were lost, then we'd put more burden on the operator to provide additional details/args

rmdmattingly avatar Oct 08 '24 13:10 rmdmattingly

@DieterDP-ng I've thought about it a little bit more, and I'm less sure about taking the path out of the BackupManifest. I like that the backups can be used, even if the original cluster and/or its backup system table has been lost.

If we removed this metadata from the backup itself, and the system table were lost, then we'd put more burden on the operator to provide additional details/args

I'm not seeing the detriment. What exactly would become harder if the path is no longer stored inside the manifest?

  • In case the operator wants to restore a backup, while the system table is still present, they'll have to do a hbase restore s3://.... (If they forget the path, they can retrieve it using hbase backup history.)
  • In case the operator want to restore a backup on an empty cluster, they'll have to do a hbase restore s3://....

DieterDP-ng avatar Oct 09 '24 07:10 DieterDP-ng

Yeah you're right, there wouldn't be a regression in usability — not sure I can even articulate my half-baked thought process from yesterday. Never mind

rmdmattingly avatar Oct 09 '24 12:10 rmdmattingly

Sorry that I've fallen off here. I'll try to get this fixed up for a re-review this week.

rmdmattingly avatar Nov 12 '24 23:11 rmdmattingly

:broken_heart: -1 overall

Vote Subsystem Runtime Logfile Comment
+0 :ok: reexec 0m 39s 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 _
_ master Compile Tests _
+0 :ok: mvndep 0m 10s Maven dependency ordering for branch
+1 :green_heart: mvninstall 3m 4s master passed
+1 :green_heart: compile 0m 58s master passed
+1 :green_heart: javadoc 0m 27s master passed
+1 :green_heart: shadedjars 5m 18s branch has no errors when building our shaded downstream artifacts.
_ Patch Compile Tests _
+0 :ok: mvndep 0m 14s Maven dependency ordering for patch
+1 :green_heart: mvninstall 2m 56s the patch passed
+1 :green_heart: compile 0m 58s the patch passed
+1 :green_heart: javac 0m 58s the patch passed
+1 :green_heart: javadoc 0m 25s the patch passed
+1 :green_heart: shadedjars 5m 13s patch has no errors when building our shaded downstream artifacts.
_ Other Tests _
+1 :green_heart: unit 0m 36s hbase-protocol-shaded in the patch passed.
-1 :x: unit 12m 57s /patch-unit-hbase-backup.txt hbase-backup in the patch failed.
35m 5s
Subsystem Report/Notes
Docker ClientAPI=1.47 ServerAPI=1.47 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/7/artifact/yetus-jdk17-hadoop3-check/output/Dockerfile
GITHUB PR https://github.com/apache/hbase/pull/6294
Optional Tests javac javadoc unit compile shadedjars
uname Linux 31a2a9c3fee1 5.4.0-195-generic #215-Ubuntu SMP Fri Aug 2 18:28:05 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/hbase-personality.sh
git revision master / d70c8dd998427da8e164f73bb97ac8f0b542adae
Default Java Eclipse Adoptium-17.0.11+9
Test Results https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/7/testReport/
Max. process+thread count 3264 (vs. ulimit of 30000)
modules C: hbase-protocol-shaded hbase-backup U: .
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/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.

Apache-HBase avatar Nov 13 '24 13:11 Apache-HBase

:confetti_ball: +1 overall

Vote Subsystem Runtime Logfile Comment
+0 :ok: reexec 0m 42s 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.
_ master Compile Tests _
+0 :ok: mvndep 0m 10s Maven dependency ordering for branch
+1 :green_heart: mvninstall 3m 10s master passed
+1 :green_heart: compile 1m 9s master passed
+1 :green_heart: checkstyle 0m 20s master passed
+1 :green_heart: spotbugs 2m 41s master passed
+1 :green_heart: spotless 0m 44s branch has no errors when running spotless:check.
_ Patch Compile Tests _
+0 :ok: mvndep 0m 11s Maven dependency ordering for patch
+1 :green_heart: mvninstall 2m 54s the patch passed
+1 :green_heart: compile 1m 9s the patch passed
+1 :green_heart: cc 1m 9s the patch passed
-0 :warning: javac 0m 30s /results-compile-javac-hbase-backup.txt hbase-backup generated 1 new + 101 unchanged - 0 fixed = 102 total (was 101)
+1 :green_heart: blanks 0m 0s The patch has no blanks issues.
-0 :warning: checkstyle 0m 11s /results-checkstyle-hbase-backup.txt hbase-backup: The patch generated 1 new + 0 unchanged - 0 fixed = 1 total (was 0)
+1 :green_heart: spotbugs 2m 56s the patch passed
+1 :green_heart: hadoopcheck 10m 20s Patch does not cause any errors with Hadoop 3.3.6 3.4.0.
+1 :green_heart: hbaseprotoc 1m 0s the patch passed
+1 :green_heart: spotless 0m 43s patch has no errors when running spotless:check.
_ Other Tests _
+1 :green_heart: asflicense 0m 21s The patch does not generate ASF License warnings.
35m 41s
Subsystem Report/Notes
Docker ClientAPI=1.47 ServerAPI=1.47 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/7/artifact/yetus-general-check/output/Dockerfile
GITHUB PR https://github.com/apache/hbase/pull/6294
Optional Tests dupname asflicense javac spotbugs checkstyle codespell detsecrets compile hadoopcheck hbaseanti spotless cc buflint bufcompat hbaseprotoc
uname Linux 5524b4beb002 5.4.0-195-generic #215-Ubuntu SMP Fri Aug 2 18:28:05 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/hbase-personality.sh
git revision master / d70c8dd998427da8e164f73bb97ac8f0b542adae
Default Java Eclipse Adoptium-17.0.11+9
Max. process+thread count 85 (vs. ulimit of 30000)
modules C: hbase-protocol-shaded hbase-backup U: .
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/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.

Apache-HBase avatar Nov 13 '24 13:11 Apache-HBase

Seems like a legitimate test failure, will dig in

rmdmattingly avatar Nov 13 '24 21:11 rmdmattingly

Ok I've fixed the test failure by ensuring that we persist the merged backup's manifest file when deleting the tmp directory. Also added some logging to help with debuggability, and I think it's worth just keeping that around.

rmdmattingly avatar Nov 15 '24 13:11 rmdmattingly

:confetti_ball: +1 overall

Vote Subsystem Runtime Logfile Comment
+0 :ok: reexec 0m 33s Docker mode activated.
-0 :warning: yetus 0m 4s Unprocessed flag(s): --brief-report-file --spotbugs-strict-precheck --author-ignore-list --blanks-eol-ignore-file --blanks-tabs-ignore-file --quick-hadoopcheck
_ Prechecks _
_ master Compile Tests _
+0 :ok: mvndep 0m 12s Maven dependency ordering for branch
+1 :green_heart: mvninstall 2m 59s master passed
+1 :green_heart: compile 0m 49s master passed
+1 :green_heart: javadoc 0m 23s master passed
+1 :green_heart: shadedjars 5m 36s branch has no errors when building our shaded downstream artifacts.
_ Patch Compile Tests _
+0 :ok: mvndep 0m 13s Maven dependency ordering for patch
+1 :green_heart: mvninstall 2m 50s the patch passed
+1 :green_heart: compile 0m 49s the patch passed
+1 :green_heart: javac 0m 49s the patch passed
+1 :green_heart: javadoc 0m 21s the patch passed
+1 :green_heart: shadedjars 5m 35s patch has no errors when building our shaded downstream artifacts.
_ Other Tests _
+1 :green_heart: unit 0m 31s hbase-protocol-shaded in the patch passed.
+1 :green_heart: unit 10m 38s hbase-backup in the patch passed.
32m 45s
Subsystem Report/Notes
Docker ClientAPI=1.43 ServerAPI=1.43 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/8/artifact/yetus-jdk17-hadoop3-check/output/Dockerfile
GITHUB PR https://github.com/apache/hbase/pull/6294
Optional Tests javac javadoc unit compile shadedjars
uname Linux 4c37c2c49f08 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 master / 3e6d98a7e31100d083a16331fddd0216e14ea3b7
Default Java Eclipse Adoptium-17.0.11+9
Test Results https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/8/testReport/
Max. process+thread count 3572 (vs. ulimit of 30000)
modules C: hbase-protocol-shaded hbase-backup U: .
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/8/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.

Apache-HBase avatar Nov 15 '24 14:11 Apache-HBase

:confetti_ball: +1 overall

Vote Subsystem Runtime Logfile Comment
+0 :ok: reexec 0m 42s Docker mode activated.
_ Prechecks _
+1 :green_heart: dupname 0m 0s No case conflicting files found.
+0 :ok: codespell 0m 0s codespell was not available.
+0 :ok: detsecrets 0m 0s detect-secrets was not available.
+0 :ok: buf 0m 0s buf was not available.
+0 :ok: buf 0m 0s 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.
_ master Compile Tests _
+0 :ok: mvndep 0m 15s Maven dependency ordering for branch
+1 :green_heart: mvninstall 2m 53s master passed
+1 :green_heart: compile 1m 9s master passed
+1 :green_heart: checkstyle 0m 19s master passed
+1 :green_heart: spotbugs 2m 42s master passed
+1 :green_heart: spotless 0m 43s branch has no errors when running spotless:check.
_ Patch Compile Tests _
+0 :ok: mvndep 0m 12s Maven dependency ordering for patch
+1 :green_heart: mvninstall 2m 49s the patch passed
+1 :green_heart: compile 1m 10s the patch passed
+1 :green_heart: cc 1m 10s the patch passed
-0 :warning: javac 0m 31s /results-compile-javac-hbase-backup.txt hbase-backup generated 1 new + 101 unchanged - 0 fixed = 102 total (was 101)
+1 :green_heart: blanks 0m 0s The patch has no blanks issues.
-0 :warning: checkstyle 0m 11s /results-checkstyle-hbase-backup.txt hbase-backup: The patch generated 1 new + 0 unchanged - 0 fixed = 1 total (was 0)
+1 :green_heart: spotbugs 2m 59s the patch passed
+1 :green_heart: hadoopcheck 10m 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 44s patch has no errors when running spotless:check.
_ Other Tests _
+1 :green_heart: asflicense 0m 20s The patch does not generate ASF License warnings.
35m 25s
Subsystem Report/Notes
Docker ClientAPI=1.47 ServerAPI=1.47 base: https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/8/artifact/yetus-general-check/output/Dockerfile
GITHUB PR https://github.com/apache/hbase/pull/6294
Optional Tests dupname asflicense javac spotbugs checkstyle codespell detsecrets compile hadoopcheck hbaseanti spotless cc buflint bufcompat hbaseprotoc
uname Linux 59aa6b57b282 5.4.0-195-generic #215-Ubuntu SMP Fri Aug 2 18:28:05 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Build tool maven
Personality dev-support/hbase-personality.sh
git revision master / 3e6d98a7e31100d083a16331fddd0216e14ea3b7
Default Java Eclipse Adoptium-17.0.11+9
Max. process+thread count 86 (vs. ulimit of 30000)
modules C: hbase-protocol-shaded hbase-backup U: .
Console output https://ci-hbase.apache.org/job/HBase-PreCommit-GitHub-PR/job/PR-6294/8/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.

Apache-HBase avatar Nov 15 '24 14:11 Apache-HBase