Repository navigation
rebase: improve copy objects of one table in parallel by rebase_concurrency - #1650
Merged
Merged
Conversation
Every CopyObject inside a table (archives, directory part files, object disk blobs) ran strictly one by one, rebase_concurrency limited only the number of tables, so a single big object disk table was pinned to one in-flight request and one slow copy stalled the whole table. rebaseTable now schedules every CopyObject into a per-table errgroup bounded by rebase_concurrency (up to rebase_concurrency^2 copies in flight), part resolution and table metadata updates stay serial. Scheduled copies must not capture the Walk callback ctx: S3.WalkAbsolute cancels it when Walk returns. Fix #1648 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Coverage Report for CI Build 40731052583Warning Build has drifted: This PR's base is out of sync with its target branch, so coverage data may include unrelated changes. Coverage increased (+0.03%) to 70.521%Details
Uncovered Changes
Coverage Regressions28 previously-covered lines in 8 files lost coverage.
Coverage Stats
💛 - Coveralls |
…ency_1648 # Conflicts: # ChangeLog.md
Without log_level: debug rebase printed nothing between start and the final "required parts copied", so a long rebase looked hung. Log the required backups chain, rebase_concurrency and max_copy_object (rebase_concurrency^2 CopyObject in flight) on start, and "rebase table start/finish" with progress, duration, copied_size and object_disk_size per table, same shape as upload/download. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Fix #1648
rebaseran everyCopyObjectinside a table (archives, directory part files, object disk blobs) strictly one by one;general.rebase_concurrencylimited only the number of tables in parallel, so one big object disk table was pinned to a single in-flight request.Changes
rebaseTableschedules everyCopyObjectinto a per-table errgroup withSetLimit(rebase_concurrency), so up torebase_concurrency^2copies are in flight; no new config knob (rebase is not object disk upload, soobject_disk_server_side_copy_concurrencyis not reused)rebaseScheduleTableParts), copied sizes are known before the copy startsWalkcallback ctx:S3.WalkAbsolutecancels its ctx whenWalkreturns (caught byTestRebaseS3Directory)context canceledTests
Walkcancels its ctx on return like S3;TestRebaseTableObjectDiskBlobsruns withrebase_concurrency1 and 4 with a 50ms mock copy delay and asserts the parallel run is fastergo test ./...,RUN_TESTS='TestRebase|TestKeepBackupRemoteWithRebase|TestDeleteRequiredBackup' ./test/integration/run.sh— all pass locally🤖 Generated with Claude Code