Coalesce encrypted blobstore backup reads#13750
Open
arnav-ag wants to merge 1 commit into
Open
Conversation
gxglass
reviewed
Jul 20, 2026
gxglass
left a comment
Collaborator
There was a problem hiding this comment.
AI review seems fine. @akankshamahajan15 do you want to double check this?
akankshamahajan15
approved these changes
Jul 20, 2026
Contributor
Result of foundationdb-pr-clang-ide on Linux RHEL 9
|
Contributor
Result of foundationdb-pr-clang-arm on Linux RHEL 9
|
Contributor
Result of foundationdb-pr on Linux RHEL 9
|
Contributor
Result of foundationdb-pr-clang on Linux RHEL 9
|
Contributor
Result of foundationdb-pr-cluster-tests on Linux RHEL 9
|
Contributor
Result of foundationdb-pr-macos-m1 on macOS 14.x
|
Contributor
Result of foundationdb-pr-macos on macOS 14.x
macOS stat flags, not linux compatiblelock_mtime() { stat -f %m $LOCK || echo 0 }
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Encrypted blobstore backups previously defaulted to 4,096-byte encryption blocks, while the blobstore read cache used 1,048,576-byte blocks. Because the cache wrapped
AsyncFileEncrypted, a 1 MiB restore read was split into roughly 256 small S3 requests before reaching the cache.The current encryption default is 1 MiB, which gives a 1:1 ratio with the default cache block. Existing backups and new backups configured with
--encryption-block-sizebelow 1 MiB still encounter the amplification.Change
Cache ciphertext between
AsyncFileEncryptedandAsyncFileBlobStoreRead, allowing adjacent encryption-block reads to share larger object-store range reads. Unencrypted reads, writes, and files underproperties/are unchanged.Validation
With 4 KiB encryption blocks, we observed approximately 256 times fewer S3 requests. A sample restore improved from 123 minutes to 103 minutes, primarily from removing S3 request overhead. The same result was achieved with default concurrent-read and blobstore-connection settings, removing the tuning previously needed to absorb the inflated request volume.
git diff --checkclang-format --dry-run --Werror fdbclient/BackupContainerBlobStore.cpp