Repository navigation
Add branding checks to CLI version banners - #2247
Merged
Merged
Conversation
oferchen
added a commit
that referenced
this pull request
May 1, 2026
oferchen
added a commit
that referenced
this pull request
May 5, 2026
3 tasks
oferchen
added a commit
that referenced
this pull request
May 16, 2026
…2247) (#4158) * fix(engine): harden reorder spill against ENOSPC and temp-dir vanish Previously `SpillableReorderBuffer` panicked on every disk failure path: ENOSPC during the spill write, a missing spill file at reload time, and short-write fallouts all translated heavy-transfer faults into process crashes that downstream consumers could neither catch nor map to an rsync exit code. This change introduces a typed `SpillError` (capacity vs I/O) and threads `Result` through `insert`, `force_insert`, `next_in_order`, and `drain_ready`. Failed spill writes now return the I/O error and re-insert the offending item so callers can shut down cleanly with exit 11. The implementation also gains an opt-in `with_spill_dir` constructor. When the explicit directory disappears mid-transfer (operator cleanup, tmpfs eviction, container restart), the buffer detects the `NotFound` error, performs a single `create_dir_all` recovery, and retries the write once before surfacing the failure. New tests cover: - ENOSPC injected through the codec, asserting `SpillError::Io` with `ErrorKind::StorageFull` and `is_out_of_space()` true. - Partial-write via a `OneByteWriter` confirming the std `write_all` contract surfaces `WriteZero` rather than silently dropping bytes. - Removing the spill directory mid-test, then asserting the next spill recreates it once (`dir_recreate_events` increments, dir exists). - `create_dir_all` failure when the parent is a regular file - error surfaces without panicking. - A round-trip on the directory-backed flavour to confirm the happy path stays byte-for-byte equivalent to the spooled default. Success-path semantics are unchanged. All pre-existing tests adapt trivially to the new `Result`-returning signatures. * fix(engine): refuse silent data loss on temp-dir vanish after spills Recovery via `create_dir_all` is only safe when nothing has been spilled yet. With prior items present on the (now-missing) disk a recreate silently loses them; the transfer would continue with a corrupted delivery stream. Return the underlying `NotFound` error in that case so the caller maps it to exit 11 and aborts cleanly. The recoverable "vanish before first spill" path still recreates the directory once and resumes. Split the existing test into two cases (pre-spill recreate succeeds; post-spill vanish surfaces an error and does not increment the recreate counter). * fix(engine): drop unused dir field from SpillBackend::Directory
3 tasks done
oferchen
added a commit
that referenced
this pull request
May 18, 2026
…2247) (#4158) * fix(engine): harden reorder spill against ENOSPC and temp-dir vanish Previously `SpillableReorderBuffer` panicked on every disk failure path: ENOSPC during the spill write, a missing spill file at reload time, and short-write fallouts all translated heavy-transfer faults into process crashes that downstream consumers could neither catch nor map to an rsync exit code. This change introduces a typed `SpillError` (capacity vs I/O) and threads `Result` through `insert`, `force_insert`, `next_in_order`, and `drain_ready`. Failed spill writes now return the I/O error and re-insert the offending item so callers can shut down cleanly with exit 11. The implementation also gains an opt-in `with_spill_dir` constructor. When the explicit directory disappears mid-transfer (operator cleanup, tmpfs eviction, container restart), the buffer detects the `NotFound` error, performs a single `create_dir_all` recovery, and retries the write once before surfacing the failure. New tests cover: - ENOSPC injected through the codec, asserting `SpillError::Io` with `ErrorKind::StorageFull` and `is_out_of_space()` true. - Partial-write via a `OneByteWriter` confirming the std `write_all` contract surfaces `WriteZero` rather than silently dropping bytes. - Removing the spill directory mid-test, then asserting the next spill recreates it once (`dir_recreate_events` increments, dir exists). - `create_dir_all` failure when the parent is a regular file - error surfaces without panicking. - A round-trip on the directory-backed flavour to confirm the happy path stays byte-for-byte equivalent to the spooled default. Success-path semantics are unchanged. All pre-existing tests adapt trivially to the new `Result`-returning signatures. * fix(engine): refuse silent data loss on temp-dir vanish after spills Recovery via `create_dir_all` is only safe when nothing has been spilled yet. With prior items present on the (now-missing) disk a recreate silently loses them; the transfer would continue with a corrupted delivery stream. Return the underlying `NotFound` error in that case so the caller maps it to exit 11 and aborts cleanly. The recoverable "vanish before first spill" path still recreates the directory once and resumes. Split the existing test into two cases (pre-spill recreate succeeds; post-spill vanish surfaces an error and does not increment the recreate counter). * fix(engine): drop unused dir field from SpillBackend::Directory
oferchen
added a commit
that referenced
this pull request
May 18, 2026
…2247) (#4158) * fix(engine): harden reorder spill against ENOSPC and temp-dir vanish Previously `SpillableReorderBuffer` panicked on every disk failure path: ENOSPC during the spill write, a missing spill file at reload time, and short-write fallouts all translated heavy-transfer faults into process crashes that downstream consumers could neither catch nor map to an rsync exit code. This change introduces a typed `SpillError` (capacity vs I/O) and threads `Result` through `insert`, `force_insert`, `next_in_order`, and `drain_ready`. Failed spill writes now return the I/O error and re-insert the offending item so callers can shut down cleanly with exit 11. The implementation also gains an opt-in `with_spill_dir` constructor. When the explicit directory disappears mid-transfer (operator cleanup, tmpfs eviction, container restart), the buffer detects the `NotFound` error, performs a single `create_dir_all` recovery, and retries the write once before surfacing the failure. New tests cover: - ENOSPC injected through the codec, asserting `SpillError::Io` with `ErrorKind::StorageFull` and `is_out_of_space()` true. - Partial-write via a `OneByteWriter` confirming the std `write_all` contract surfaces `WriteZero` rather than silently dropping bytes. - Removing the spill directory mid-test, then asserting the next spill recreates it once (`dir_recreate_events` increments, dir exists). - `create_dir_all` failure when the parent is a regular file - error surfaces without panicking. - A round-trip on the directory-backed flavour to confirm the happy path stays byte-for-byte equivalent to the spooled default. Success-path semantics are unchanged. All pre-existing tests adapt trivially to the new `Result`-returning signatures. * fix(engine): refuse silent data loss on temp-dir vanish after spills Recovery via `create_dir_all` is only safe when nothing has been spilled yet. With prior items present on the (now-missing) disk a recreate silently loses them; the transfer would continue with a corrupted delivery stream. Return the underlying `NotFound` error in that case so the caller maps it to exit 11 and aborts cleanly. The recoverable "vanish before first spill" path still recreates the directory once and resumes. Split the existing test into two cases (pre-spill recreate succeeds; post-spill vanish surfaces an error and does not increment the recreate counter). * fix(engine): drop unused dir field from SpillBackend::Directory
oferchen
added a commit
that referenced
this pull request
Aug 24, 2026
…2247) (#4158) * fix(engine): harden reorder spill against ENOSPC and temp-dir vanish Previously `SpillableReorderBuffer` panicked on every disk failure path: ENOSPC during the spill write, a missing spill file at reload time, and short-write fallouts all translated heavy-transfer faults into process crashes that downstream consumers could neither catch nor map to an rsync exit code. This change introduces a typed `SpillError` (capacity vs I/O) and threads `Result` through `insert`, `force_insert`, `next_in_order`, and `drain_ready`. Failed spill writes now return the I/O error and re-insert the offending item so callers can shut down cleanly with exit 11. The implementation also gains an opt-in `with_spill_dir` constructor. When the explicit directory disappears mid-transfer (operator cleanup, tmpfs eviction, container restart), the buffer detects the `NotFound` error, performs a single `create_dir_all` recovery, and retries the write once before surfacing the failure. New tests cover: - ENOSPC injected through the codec, asserting `SpillError::Io` with `ErrorKind::StorageFull` and `is_out_of_space()` true. - Partial-write via a `OneByteWriter` confirming the std `write_all` contract surfaces `WriteZero` rather than silently dropping bytes. - Removing the spill directory mid-test, then asserting the next spill recreates it once (`dir_recreate_events` increments, dir exists). - `create_dir_all` failure when the parent is a regular file - error surfaces without panicking. - A round-trip on the directory-backed flavour to confirm the happy path stays byte-for-byte equivalent to the spooled default. Success-path semantics are unchanged. All pre-existing tests adapt trivially to the new `Result`-returning signatures. * fix(engine): refuse silent data loss on temp-dir vanish after spills Recovery via `create_dir_all` is only safe when nothing has been spilled yet. With prior items present on the (now-missing) disk a recreate silently loses them; the transfer would continue with a corrupted delivery stream. Return the underlying `NotFound` error in that case so the caller maps it to exit 11 and aborts cleanly. The recoverable "vanish before first spill" path still recreates the directory once and resumes. Split the existing test into two cases (pre-spill recreate succeeds; post-spill vanish surfaces an error and does not increment the recreate counter). * fix(engine): drop unused dir field from SpillBackend::Directory
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
Testing
[Codex Task](