apple / apple/foundationdb

fdbrestore should perform cluster checks before and after listing the backup files

Open
#3,058 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
16.7k
Forks
1.6k
Avg merge
1d 20h
Merged PRs (30d)
126

Description

Until https://github.com/apple/foundationdb/issues/3043 is complete, its possible that forcing a version jump (for multi-cluster DR) will cause fdbbackup to write millions of empty files.

fdbrestore has a step that lists every file in the backup using platform::findFiles(). It then checks if the destination cluster is ready for restore (checks for duplicate restore jobs, that the destination keyrange is empty, etc). It would be nice if these checks happen before the list file step as well, since in this millions of empty files case, this step can take an hour.

Contributor guide

Open the contributing guide

Research direction

Start at the fdbrestore entry point and locate the platform::findFiles() step alongside the existing destination-cluster readiness checks. Ensure those checks also run before listing backup files, while preserving the current post-list checks; done means restore jobs and destination keyrange validation can reject an unsuitable restore without first scanning every file.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
databases, distributed-systems
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.