feat(transfer): bypass ReorderBuffer when delay-updates is off (#1886)#3988
Merged
Conversation
Add passthrough mode to both ReorderBuffer (engine) and BoundedReorderBuffer (transfer) that skips sequence-based reordering. When --delay-updates is disabled, files are committed immediately upon completion, making strict file-list ordering unnecessary. The bypass eliminates per-item ring buffer and BTreeMap overhead by routing items through a lightweight FIFO queue. Wire the bypass through DeltaConsumer::spawn_bypass(), ParallelDeltaPipeline::new_bypass(), and ThresholdDeltaPipeline::new_bypass() so callers can opt in based on transfer configuration.
2 tasks
oferchen
added a commit
that referenced
this pull request
May 18, 2026
#3988) * feat(transfer): bypass ReorderBuffer when delay-updates is off (#1886) Add passthrough mode to both ReorderBuffer (engine) and BoundedReorderBuffer (transfer) that skips sequence-based reordering. When --delay-updates is disabled, files are committed immediately upon completion, making strict file-list ordering unnecessary. The bypass eliminates per-item ring buffer and BTreeMap overhead by routing items through a lightweight FIFO queue. Wire the bypass through DeltaConsumer::spawn_bypass(), ParallelDeltaPipeline::new_bypass(), and ThresholdDeltaPipeline::new_bypass() so callers can opt in based on transfer configuration. * fix(transfer): remove unused bypass_queue field from BoundedReorderBuffer
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.
Summary
passthrough()constructor andis_passthrough()accessor to bothReorderBuffer(engine crate) andBoundedReorderBuffer(transfer crate) that skip sequence-based reordering, delivering items in insertion order via a lightweightVecDequeFIFO queueDeltaConsumer::spawn_bypass(),ParallelDeltaPipeline::new_bypass(), andThresholdDeltaPipeline::new_bypass()so callers can opt in based on--delay-updatesconfiguration--delay-updatesis off, files are committed immediately upon completion - strict file-list ordering is unnecessary, and the bypass eliminates per-item ring buffer slot indexing and BTreeMap overheadTest plan
CapacityExceeded/BackpressureErrordrain_ready()yields all items from the FIFO queue in passthrough modeforce_insert()appends to the queue in passthrough modefinish()succeeds when drained, panics when items remain (passthrough)take()returnsNonein passthrough mode (indexed extraction not supported)is_passthrough()returns correct value for both modesDeltaConsumer::spawn_bypass()delivers all results from parallel workersParallelDeltaPipeline::new_bypass()delivers all results via trait objectThresholdDeltaPipeline::new_bypass()falls back to sequential below threshold, uses bypass parallel above